ChallengeAid application development using cakePHP framework: To develop a web application in PHP and MySql, we should consider few things Scope of the application to add up new features Organization of the coding part which should be easy to debug Fast and robust Security The CakePHP framework represents a robust base for handling every aspect of a web application, from the user's initial request to the final rendering of a web page. Following the principles of MVC (model, view, controller), the framework allows us to easily customize and extend most aspects of our application. It also offers a basic organizational structure, from filenames to database table names, keeping our entire application consistent, logical and secure. Beside Controllers, Models and Views CakePHP features also Component, Behavior and Helper classes. CakePHP comes with a set of core components we can use to aid in: • Security • Sessions • Access control lists • Emails • Cookies • Authentication Request handling How Secure? Not only the MVC principles (model-view-controller) to separate the database, logic and the data-presentation, CakePHP also comes with built-in tools for Input validation, CSRF protection, Form tampering protection, SQL injection prevention, and XSS prevention, Which help us to keep our application safe & secure. Basic Components of this framework: Controllers: Contains the logic of our application. Each controller can offer different functionality; controllers retrieve and modify data by accessing database tables through models; and they register variables and objects, which can be used in views. Models Models are active representations of database tables and are used in CakePHP applications for data access purposes. They can connect to our database; query it in case they are instructed to do so by a controller, and save data to the database. A model usually represents a database table can also be used to access anything that stores data such as files, LDAP records, iCal events or rows in a CSV file. In order for the MVC architecture to be correctly applied, there must be no interaction between models and views. Instead, all the logic should be handled by the controllers. Views can be described as template files that present their content to the user: variables, arrays and objects that are used in views are registered through a controller. Views should not contain complex business logic; only the elementary control structures necessary to perform particular operations, such as the iteration of collected data through a for each construct, should be contained within a view. Helpers Helpers represent component-like classes for the presentation layer of our application, which contain presentational logic shared between many views, elements or layouts. The CakePHP framework needs a controller in order to make usage of helpers. Each controller has a $helpers property that lists the helpers to be made available in the view. To enable a helper in your view, add the name of the helper to the controller’s $helpers array. Behaviors Model behaviors allow us to separate logic that may not be directly related to a model but has to be there and to attach functionality to models by defining a simple class variable. Behaviors enable models to get rid of the extra weight, which might not be part of the business contract they are modeling, or which is needed in different models and can be then extrapolated. Components Components represent packages of logic that are shared between the controllers. If we want to copy and paste stuff between the controllers, we may have to consider wrapping some functionality in a component. CakePHP comes with a set of core components we can use to aid in: • Security • Sessions • Access control lists • Emails • Cookies • Authentication • Request handling Vendor: Which is to help us to integrate with any other 3rd party API. Such as we can integrate Facebook SDK in cakePHP framework. So in vendor folder we keep all the 3rd party and access them from our application.