The O'Reilly Network has a new article this morning targeted towards those out there wondering what page controllers are and what is so life-changing about using them in your code.
Mixed code/HTML tools--PHP, JSP, ASP, and so on--give web developers the power to create dynamic sites with little effort. They also make it easy to slip into bad habits. Consider the all-in-one page, or Model 1 architecture, in which a lone page handles an entire action by itself, typically in poor fashion. An example page might display a form, validate the submission, process the data, and show the user a thank-you message.
Developers can maintain their sanity by refactoring such an app or redesigning it in flight. The refactoring cure for the all-in-one page is the Page Controller. This design pattern is appropriate in places where a single component has the dual responsibilities of logic and display.
The article continues on, offering a little history/theory behind the patterns. From there, they move info the move into some code. Round that off with a list of four steps to dive in and make the move...




