Most Important Frequently Asked Cakephp Interview Questions
Interview Quesions on Cakephp
-
Answer :
CakePHP is a free, open-source, rapid development framework for PHP. It’s a foundational structure for programmers to create web applications. CakePHP goal is to enable developers to work in a structured and rapid manner–without loss of flexibility. CakePHP takes the monotony out of web development.
-
Question 2. When Cakephp Was Developed?
Answer :
CakePHP started in April 2005.When a Polish programmer Michal Tatarynowicz wrote a minimal version of a Rapid Application Framework in PHP, dubbing it Cake.CakePHP version 1.0 released in May 2006.
PHP Interview Questions -
Question 3. What Is The Current Stable Version Of Cakephp?
Answer :
3.0 (on date 2015-06-12).
-
Question 4. What Is Mvc In Cakephp?
Answer :
Model view controller (MVC) is an architectural pattern used in software engineering.
Model : Database functions exist in the model
View : Design parts written here
Controller : Business Logic goes here PHP Tutorial -
Question 5. Server Requirements For Cakephp?
Answer :
Here are the requirements for setting up a server to run CakePHP:
- An HTTP server (like Apache) with the following enabled: sessions, mod_rewrite (not absolutely necessary but preferred)
- PHP 4.3.2 or greater. Yes, CakePHP works great in either PHP 4 or 5.
- A database engine (right now, there is support for MySQL 4+, PostgreSQL and a wrapper for ADODB).
MySQL Interview Questions -
Question 6. How To Install Cakephp?
Answer :
step1: Go to cakephp.org and download the latest version of cakephp.
step2: Cakephp comes in a .zip file,so unzip it.
step3: Extract the files in the localhost in the desired folder (for example:cakephp).
step4: Open the browser and run the URL localhost/cakephp
step5: Just Follow the instructions display on the page.
-
Question 7. What Is The Folder Structure Of Cakephp?
Answer :
cakephp/
app/
Config/
Console/
Controller/
Lib/
Locale/
Model/
Plugin/
Test/
tmp/
Vendor/
View/
webroot/
.htaccess
index.php
lib/
plugins/
vendors/
.htaccess/
index.php/
README.md/ MySQL Tutorial PHP+MySQL Interview Questions -
Question 8. What Is The Name Of Cakephp Database Configuration File Name And Its Location?
Answer :
Default file name is database.php.default.
Its located at "/app/config/database.php.default".To connect with database it should be renamed to database.php
-
Answer :
bootstrap.php
yes it can be changed.Either through index.php , or through .htaccess
Drupal Interview Questions -
Answer :
- The Security.salt is used for generating hashes.we can change the default Security.salt value in /app/Config/core.php.
- The Security.cipherseed is used for encrypt/decrypt strings.We can change the default Security.cipherSeed value by editing /app/Config/core.php.
Drupal Tutorial -
Question 11. What Are Controllers?
Answer :
A controller is used to manage the logic for a part of your application. Most commonly, controllers are used to manage the logic for a single model. Controllers can include any number of methods which are usually referred to as actions. Actions are controller methods used to display views. An action is a single method of a controller.
MYSQL DBA Interview Questions -
Question 12. What Is Default Function For A Controller?
Answer :
index() function
PHP Interview Questions -
Question 13. Which Function Is Executed Before Every Action In The Controller?
Answer :
function beforeFilter()
WordPress Tutorial -
Question 14. List Some Of The Features In Cakephp?
Answer :
- Compatible with versions 4 and 5 of PHP
- MVC architecture
- Built-in validations
- Caching
- Scaffolding
- Access Control Lists and Authentication.
- CSRF protection via Security Component.
-
Question 15. Using Cakephp, What All Are Drawbacks?
Answer :
It loads full application before it starts your task. It's not recommended for small projects because of its resource-heavy structure.
PHP5 Interview Questions -
Question 16. What Is The Naming Convention In Cakephp?
Answer :
Table names are plural and lowercased,model names are singular and CamelCased: ModelName, model filenames are singular and underscored: model_name.php, controller names are plural and CamelCased with *Controller* appended: ControllerNamesController, controller filenames are plural and underscored with *controller* appended: controller_names_controller.php.
Joomla Tutorial -
Question 17. What Is Scaffolding In Cakephp?
Answer :
Scaffolding is a technique that allows a developer to define and create a basic application that can create, retrieve, update and delete objects.
WordPress Interview Questions -
Question 18. How To Add Scaffolding In Your Application?
Answer :
To add scaffolding to your application,just add the $scaffold variable in the controller,
<?php
class PostsController extends AppController {
var $scaffold;
}
?>Assuming you’ve created Post model class file (in /app/Model/post.php).
MySQL Interview Questions -
Question 19. What Is A Component In Cakephp?
Answer :
Components are packages of logic that are shared between controllers. They are useful when a common logic or code is required between different controllers.
CakePHP Tutorial -
Question 20. What Are Commonly Used Components Of Cakephp?
Answer :
- Security
- Sessions
- Access control lists
- Emails
- Cookies
- Authentication
- Request handling
- Scaffolding
Joomla Interview Questions -
Question 21. What Is A Helper?
Answer :
Helpers in CakePHP are associated with Presentation layers of application.Helpers mainly contain presentational logic which is available to share between many views, elements, or layouts.
-
Question 22. What Are Commonly Used Helpers Of Cakephp?
Answer :
- FormHelper
- HtmlHelper
- JsHelper
- CacheHelper
- NumberHelper
- Paginator
- RSS
- SessionHelper
- TextHelper
- TimeHelper
CodeIgniter Tutorial -
Question 23. What Is A Behavior?
Answer :
Behaviors in CakePHP are associated with Models.Behaviors are used to change the way models behaves and enforcing model to act as something else.
CodeIgniter Interview Questions -
Question 24. What Is The Difference Between Component, Helper, Behavior?
Answer :
Component is a Controller extension, Helpers are View extensions, Behavior is a Model Extension.
PHP+MySQL Interview Questions -
Question 25. What Is A Element?
Answer :
Element in cakephp are smaller and reusable bits of view code. Elements are usually rendered inside views.
PHP7 Tutorial -
Question 26. What Is A Layout?
Answer :
Layout in cakephp are used to display the views that contain presentational code. In simple views are rendered inside a layout.
Topic: Cakephp Interview Questions
Interview Quesions on Cakephp
No comments:
Post a Comment