R
R
Rathil2012-11-16 18:57:58
PHP
Rathil, 2012-11-16 18:57:58

PHP template engine

What is currently the most popular template engine in your opinion?
Well, or what kind of template engine do you use and why? What is better / more conveniently done in it compared to others?

Answer the question

In order to leave comments, you need to log in

10 answer(s)
M
Mike Grigorieff, 2012-11-16
@Rathil

Twig

S
sba, 2012-11-16
@sba

The best templating engine for PHP is PHP itself. This language is designed for just such purposes. With proper separation of business logic and presentation logic, we get the desired result with zero overhead.

C
chetzof, 2012-11-16
@chetzof

I used to think that the best template engine is PHP and terribly argued with everyone who did not agree with this, after I had to use Twig, I radically changed my position. Very convenient, twig constructions are much shorter than their counterparts in php, there is support in an IDE, such as PhpStorm. In terms of performance, there is practically no overhead, they are compiled into php code on the first run.

S
Sergey, 2012-11-16
Protko @Fesor

twig. There are several reasons. Very convenient and clear syntax, filters/functions, template compilation, template inheritance. It is implemented using an AST parser, so it is quite convenient to expand the syntax.

D
dezconnect, 2012-11-16
@dezconnect

probably popular twig. I myself use Blitz, as it connects with a separate extension. not an extra folder.

A
ArtEx, 2012-11-16
@ArtEx

Previously (2007-2011) I used Smarty - a fairly powerful and understandable template engine. Moreover, it certainly worked no slower than Twig.

D
Denis, 2012-11-16
@karneds

Probably the most popular twig. But I like Jade better . There is an implementation in php, scala, ruby, python, java.

W
wartur, 2012-11-16
@wartur

Your own. Right now it only works under Yii. Yii + this thing really solves all the tasks that are needed in the application.
github.com/wartur/yii-thplike

K
kolesnevg, 2012-11-16
@kolesnevg

RainTPL

N
Nazar Mokrinsky, 2012-11-17
@nazarpc

I also use my own syntax a la haml, but native, I wrote an example of use in this comment . Requires PHP 5.4

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question