View Single Post
  #7 (permalink)  
Old 09-01-2008, 02:56 AM
orjan's Avatar   
orjan orjan is offline
Programming Expert
 
Join Date: Sep 2007
Location: Sunne, Värmland, Sweden
Age: 33
Posts: 359
Last Blog:
Procedural Programming...
Credits: 42
Rep Power: 9
orjan has a spectacular aura aboutorjan has a spectacular aura aboutorjan has a spectacular aura about
Talking Re: Creating template system for my own cms

Quote:
Originally Posted by John View Post
Smarty is has to be one of the most asinine creations I know of. What the hell good is using a custom syntax just to run every tpl file through a smarty defined parsing function to convert that custom syntax back to php? That defeats the entire purpose of php to begin with.
Well, how would a template engine work otherwise, if not being a mid-layer in between the produced data and the finished html?

in this way, you can, with the same code, in an very easy way, make totally different layouts with the same data, even for two users at the same time.

maybe there are better template engines, That I can't tell, but I've found the smarty engine to work well for me, then I can create my coding, and then a designer can work with the tpl-files how they like without disturbing the code at all, just inserting variables (and a few control parameters) into their design-html-code.

maybe you have some good suggestions of how to create layout templates in other ways?
Reply With Quote