I am trying to better understand the MVC architecture. I am writing front-end and back-end web applications using the LAMP stack. I do not use any frameworks yet. I have code in Notepad ++ and use WinSCP to transfer files (Putty for terminal). All server-side encodings are performed in PHP.
Based on the reading I did, this is my best guess about how MVC files are structured:
+
| +
| | +
| +
| | +
| +
| | +
+
| +
| | +
| +
| | +
| +
| | +
So, although there are many articles and blogs about which models, views, and controllers are, I have not seen anything about how to set this up for what I have compiled above.
I have no idea how this integrates with respect to my shared folder on my server. Here is my hunch, assuming it /var/www/html/is my public directory.
+ -- var
| + -- www
| | + -- html
| | | + -- my-application-1.php
| | | |
| | | + -- my-application-2.php
| | + -- Project1
| | | + -- models
| | | | + -- model.php
| | | + -- views
| | | | + -- view.php
| | | + -- controllers
| | | | + -- controller.php
| | + -- Project2
| | | + -- models
| | | | + -- model.php
| | | + -- views
| | | | + -- view.php
| | | + -- controllers
| | | | + -- controller.php
, ( , ), "" . , (my-application1.php my-application-2.php), (php include/require) , . , .
- ? Linux-? -, , , ?
, (, Zend, Laravel CakePHP). , , , , .