I agree, MVC is the way to go... I should really release my own framework I've developed over the past 10 years to the public, I'm sure the PHP community would love it...
But I'm torn, I'm also a big supporter of private enterprise and my framework has been hard won. It's my bread and butter and I can develop things in a fraction of the time it takes other developers.
Being OO, completely modular, and using true MVC design principals so that I can swap out a data source without ever touching a controller or view... I use DatabaseObjects for example:
Class User extends MySQLObject, it has common methods used across any Parent DB Object Class...
$user = new User($id);
$user->getFormData();
$user->updateDB();
That's all I need to write in order to process form data, populate the new data for a user row and update the database... Everything is handled out of my way, cleaning, escaping, structuring the SQL, etc...
If I want to handle users through LDAP, it's easy
Class User extends LDAPObject
$user = new User($id);
$user->getFormData();
$user->updateDB();
I have prebuilt parent classes for SQL Server, Oracle, Postgres, MySQL, LDAP, and even flat file storage... I can swap from data source to data source with a few characters worth of changes...
Anyway, probably boring 99% of the people in here but that's an insight into the data side of things in my own code :P
+1 MVC
__________________
ICQ: 258-202-811 | Email: eric{at}bestxxxporn.com
|