InterviewSolution
| 1. |
Explain MVC in codeIgnitor. |
|
Answer» CodeIgnitor is based on MVC. Acronym for Model View Control. MVC separates application logic from presentation logic. As the presentation is separated from PHP logic so page CONTAINS less scripting and provides FASTER loading. Model REPRESENTS data structures Model CLASSES will contain functions that help to retrieve update and insert information into the database. Controller holds all application logic, serves as an intermediary between model and view and any other resources NEEDED to process request. View is the information that is been passed to the user. View is normally a web page but in CodeIgnitor it can be a part of a page like a header, footer, nav, etc. CodeIgnitor holds a loosely MVC approach. If your application doesn’t require a model, you can ignore them and can build an application with View and controllers. |
|