Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it worth learning Smarty for PHP templating? [closed]

I'm building a simple 10-page site using an MVC-like architecture. Is it worth learning the Smarty templating engine?

like image 376
Trent Scott Avatar asked May 17 '11 04:05

Trent Scott


1 Answers

Template engines add overhead.

You should only use a template engine if you need to have others create/edit templates and you do not want them to be able to use PHP.

If you are the sole maintainer, defiantly go with plain PHP. If your team can be trusted (they are all devs), stick with plain PHP. If you have designers that don't know PHP or, more importantly, letting them use PHP is dangerous, then use Smarty or another template engine.

That being said, you are wondering if you should learn Smarty. You'll need to learn Smarty if creating templates with Smarty. You don't really need to learn Smarty if you are just implementing the Smarty template engine.

like image 150
d-_-b Avatar answered Sep 22 '22 11:09

d-_-b