Home >Common Problem >What are the benefits of mvc framework

What are the benefits of mvc framework

藏色散人
藏色散人Original
2020-08-05 09:00:0512186browse

The benefits of the mvc framework are: 1. Allowing the view layer code to be changed without recompiling the model and controller code; 2. Allowing the use of various different styles of views to access the same server-side code; 3. Using It is possible to reduce the technical content of developing and maintaining user interfaces; 4. Development time can be greatly reduced, etc.

What are the benefits of mvc framework

Recommended: "PHP Video Tutorial"

mvc Framework

The process is as follows:

First, the view sends a request to the controller, and the controller then sends the business request to the model,

Then the model processes the request business and returns the results to the controller, and the controller selects the

view based on the results.

Advantages of MVC:

1. Low coupling:

The view layer and business layer are separated, which allows the view layer code to be changed without Recompile model and controller code. Similarly, changes to the business process or business rules of an application only require changes to the model layer of MVC. Because the model is separated from the controller and view, it is easy to change the data layer and business rules of the application.

2. High reusability and applicability

The MVC model allows you to use various different styles of views to access the same server-side code. It includes any WEB (HTTP) browser or wireless browser (wap). For example, a lot of data may be represented by HTML, but it may also be represented by WAP, and all that is required for these representations is to change the view layer. Implementation method without any changes in the control layer and model layer.

3. Lower life cycle cost

MVC makes it possible to reduce the technical content of developing and maintaining user interfaces.

4. Rapid deployment

Using the MVC model greatly reduces development time. It allows programmers (Java developers) to concentrate on business logic, and interface programmers (HTML and JSP developers) focus on presentation

5. Maintainability

Separating the view layer and business layer also makes WEB applications easier to maintain and modify

6. Conducive to software engineering management

Since different layers perform their own duties, different applications at each layer have certain same characteristics, which is conducive to program code management through engineering and tooling.

The above is the detailed content of What are the benefits of mvc framework. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn