Powered By

Example of MVC Architecture

Example of MVC architecture:

1. When the user Log In on the login page, a request is sent to the servlet handler.

2. The servlet handler dispatches the request to the appropriate control class. In this case, Login control.

3. The Control performs the action requested by the user on the Model; in this case the Login Model.

4. The Model returns a response; in this example, a successful login message.

5. The Control either redirects to another page or returns to the same page with new data since the Model has
been updated. In this case, the Control redirects to the MyPage.

6. The Interpreter gets the HTML for the page requested by the Control from the appropriate View, in this
case the MyPage View

7. The View returns the HTML for the page.

8. The Interpreter sends the HTML for the page back to the browser.

This is what happening while you are using MVC architecture. Isn't it structured and understandable. Am sure your answer is yes. So in coming posts we will develop a simple MVC application using php with the help of ZEND framework.

Related Posts by Categories