inc.php";
?>
Because the design and logic are inextricably intertwined, several problems
soon arise:
??? Designers who were hired with the sole purpose of making your Web site look
great are now distracted by the task of having to learn PHP.
??? Developers who were hired to help out with the expansion of Web site features
are now distracted by fixing the bugs and security problems introduced by the
novice PHP code written by the designers. In the process, they decide to make
their own little tweaks to the site design, infuriating the designers.
??? Although a proper code versioning system has been deployed, the almost
constant conflicts that arise due to simultaneous editing of the same set of files
soon become tiresome and time consuming.
You??™re probably noticing a pattern here: the lack of separation of concerns is
breeding an environment of pain, distrust, and inefficiency. But there is a solution
that can go a long way toward alleviating these issues: the MVC architecture.
The MVC approach renders development more efficient by breaking the application
into three distinct components: the model, the view, and the controller. Doing so
allows for each component to be created and maintained in isolation, thereby minimizing
the residual effects otherwise incurred should the components be intertwined
in a manner similar to that illustrated in the previous example.
Pages:
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689