Web

How to design with php ?

Design pattern designates a recurring way of solving a programming problem; Usually via object-oriented programming, but not always. Over time, certain conceptions have become recurrent in certain situations and have been documented, named and standardized. In the web domain, the Design Pattern Model View Controller (MVC) is one of them.

The Design Pattern MVC

In a project, a software engineering approach pushes to define the architecture of an application while respecting the design pattern. The MVC architecture seeks to separate three things:
- how to access the data,
- man / machine interface: design, design,
- processing related to the trade / field of application.

The controllers are used to respond to the actions of the user. Each control is associated with a view: this view makes it possible to present the information returned to the user. The data comes from the model (business logic).

Patterns have a history and are not fixed. Thus, the MVC pattern evolved towards the MVC2. In the MVC 2 architecture, there is only one controller that receives all client requests.
The single controller becomes the exclusive entry point of the application. It becomes very easy to centralize the management of access, rights, statistics or any other transverse functionality.

This architecture is particularly recommended in the implementation of a Web application for many reasons.
The single point of entry allows the implementation of centralized processing. Typically, access control. Rather than copy paste (and forget) a test on each page to verify that the user is identified. This test is performed once and this code is maintained in one place.

The code is also much easier to maintain

The sequence of the screens is defined by the single point of entry, a modification will be made at this place (and not by going in search of the 90 lost links in a mountain of code). If tomorrow the product is no longer to be sought in the database but in a web service, it is easy to modify only the corresponding DAO without impacting the business logic.
And if the design evolves, only the files of the view are concerned.

For more information about php programming, click here !

Les publications similaires de "Develop your website"

  1. 20 Nov. 2020Where to find the best Php developers offshore13 vues
  2. 30 Oct. 2020Embrace projects in web development and programming43 vues
  3. 30 Sept. 2020A team of very high end Php programmers to hire74 vues
  4. 29 Août 2020The Php web development needed for your website137 vues
  5. 22 Fév. 2020Where to learn the code ??388 vues
  6. 25 Juin 2019How to start to develop in PHP ?768 vues
  7. 7 Fév. 2019The difference inbetween Php and magneto developers807 vues
  8. 30 Août 2018Why you can rely on Koodos for web solutions996 vues
  9. 5 Mai 2018Hire today's top PHP developers1418 vues
  10. 28 Fév. 2018The differences between a static and a dynamic website1228 vues
  11. 1 Juil. 2017Magento is super easy to do product table !1642 vues
  12. 3 Avril 2017What is the advantage of hiring an agency?1446 vues
  13. 27 Janv. 2017The technique advances and the language of programming progress. We are at the forefront1487 vues