04-30-2009, 09:39 PM
|
#13 (permalink)
|
|
The Frequenter
Join Date: Dec 2007
Location: Bucharest, Romania
Posts: 438
Thanks: 3
|
A template doesn't need to connect to the database. As it doesn't require ANY resources to parse and display it (I am here referring to CSS - which is the presentational part of an application or a website, but not tied to the template files themselves - and JavaScript - which is the functionality given to the client by the application as a whole, not by the template files). So, I'd suggest you stick to the purpose, and that's all. Make a connector between a template file and the database (that would be the Controller in an MVC oriented system), and use that to perform operations on the DB, and do other stuff like that which doesn't have anything at all to do with the purpose of templating an application/web site/etc.
__________________
I have optimistic thoughts, even though sometimes (if not always) life's a bitch.
|
|
|
|