Application Structure: Application Structure Overview (2024)

5 followers

Yii applications are organized according to the model-view-controller (MVC)architectural pattern. Models represent data, business logic and rules; viewsare output representation of models; and controllers take input and convertit to commands for models and views.

Besides MVC, Yii applications also have the following entities:

  • entry scripts: they are PHP scripts that are directly accessible by end users.They are responsible for starting a request handling cycle.
  • applications: they are globally accessible objects that manage application componentsand coordinate them to fulfill requests.
  • application components: they are objects registered with applications andprovide various services for fulfilling requests.
  • modules: they are self-contained packages that contain complete MVC by themselves.An application can be organized in terms of multiple modules.
  • filters: they represent code that need to be invoked before and after the actualhandling of each request by controllers.
  • widgets: they are objects that can be embedded in views. Theymay contain controller logic and can be reused in different views.

The following diagram shows the static structure of an application:

Application Structure: Application Structure Overview (1)

Found a typo or you think this page needs improvement?
Edit it on github !

Application Structure: Application Structure Overview (2024)
Top Articles
Latest Posts
Article information

Author: Delena Feil

Last Updated:

Views: 6654

Rating: 4.4 / 5 (45 voted)

Reviews: 84% of readers found this page helpful

Author information

Name: Delena Feil

Birthday: 1998-08-29

Address: 747 Lubowitz Run, Sidmouth, HI 90646-5543

Phone: +99513241752844

Job: Design Supervisor

Hobby: Digital arts, Lacemaking, Air sports, Running, Scouting, Shooting, Puzzles

Introduction: My name is Delena Feil, I am a clean, splendid, calm, fancy, jolly, bright, faithful person who loves writing and wants to share my knowledge and understanding with you.