MVC stands for Model-View-Controller. Its purpose to distinctly separates the way data is handled, the way the functions is handled, and the handling the interaction between the user.
Model handles the interaction between the database. Model is responsible in collecting and storing data in the database. It's usual function is to Create, Read, Update and Delete or in short CRUD.
View handles what the user can see(or hear) like the designs, animations, sounds, videos, etc. It also handles the user inputs like names, comments, post, and etc. which will be save in the database using the model.
Controller is responsible for the interaction between the Model and/or View. It also handles what is going to be displayed in the View. Common function of the Controller get the user input from the View then pass it to the Model for saving and vice versa.
No comments:
Post a Comment