> -----Original Message----- > From: Bob McConnell [mailto:rvm@xxxxxxxxx] > Sent: Friday, February 27, 2009 9:56 AM > To: PHP General list > Subject: Development methods (was: "use strict" or similar in > PHP?) > > From: Boyd, Todd M. > > Well, take care of all of your logic before you display anything. > It's > > not that difficult, to be honest... especially if you're already > using > > an MVC design pattern/framework or a template system. > > That's an interesting string of buzzwords, but it carries no meaning > for > me. Would you care to elucidate further? > > As far as the code I am working with, I inherited over 160 files of > mixed HTML and PHP, where the logic and presentation are intermingled > (mangled) throughout. My initial toolset was TextPad4, WinSCP and Putty > on a WinXP workstation, with Apache on RHEL 5 as the server. (The > original coder used vi on a clone of the server until they took it away > from him.) The chances of re-implementing the entire project are > roughly > equivalent to a zero with the edges rubbed out. I already have a six > month to-do list just adding the new features already requested by > current clients. * MVC = Model-View-Controller [1] * Template = Basically just the display (View) with variables injected [2] * Output Buffer = Output isn't sent to the browser until you deem it so [3] As far as inheriting more than 160 files with logic and presentation intermingled... I think you're pretty much SOL with regard to converting it to a framework or a new design pattern. It's possible, but that's going to be quite a bit of work. Links: 1. http://en.wikipedia.org/wiki/Model-View-Controller 2. http://www.smarty.net/ (just an example of one templating system) 3. http://www.php.net/ob_start HTH, // Todd -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php