[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Dolibarr-dev] Smarty 3

From: Laurent Destailleur (eldy)
Subject: Re: [Dolibarr-dev] Smarty 3
Date: Fri, 08 Jul 2011 01:00:04 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv: Gecko/20110516 Thunderbird/3.1.10

Le 05/07/2011 11:57, Régis Houssin a écrit :
php is natively a template generator,
 it consumes less memory than the third generator and it avoids adding a
layer, this coupled with an opcode cache (APC, eAccelerator)
 it is better than smarty.

Le 05/07/11 11:25, Juanjo Menent a écrit :
What are the reasons (about smarty 3)?

They have improved the speed and security, and would be good to improve
the design (could attract more designers...)
Smarty is a preprocessor, BEFORE PHP. It can't be faster than PHP alone. When we say "speed of smarty is increase", it is in fact the overtime spent by smarty that is reduced, not the speed of processing PHP file once smarty has finished its job. We should says "the slowing effect of using smarty is reduced", but not "the speed is increased".

Also having a template is completely possible by doing a .tpl.php file that dos not contains any logic code but only html and echo. Same result but faster and easier to develop because it does not need to do all the setXXX before calling each template. All variables are already known into a php templates. No risk to forget a set, and a lot of line of codes reduced.

There is a ton of other reasons. But only one to use Smarty :  Smarty is interesting when teams building design is complety different than team building logic code, AND if you build not too sophisticated pages, AND with no need of too many Ajax features (this need to know how code works).
And this situation is surely not the Dolibarr future (team will often be same, ajax will be more and more present event if i hope not too much, and screens are more and more dependent of dynamic or contextual events, difficult to have with smarty without transforming smarty into a PHP language).

El mar, 05-07-2011 a las 10:17 +0200, Régis Houssin escribió:
Dolibarr not use smarty, this library is deprecated

Le Tue Jul  5 09:11:37 2011, Juanjo Menent a écrit :

Smarty 3 brings many improvements over smarty 2.

It would be good idea to update the smarty includes to smarty 3?

Dolibarr-dev mailing list
address@hidden <mailto:address@hidden>

Dolibarr-dev mailing list
address@hidden <mailto:address@hidden>

Dolibarr-dev mailing list

_______________________________________________ Dolibarr-dev mailing list address@hidden

Eldy (Laurent Destailleur).
EMail: address@hidden

Dolibarr (Project leader):
To make a donation for Dolibarr project via Paypal: address@hidden
AWStats (Author) :
To make a donation for AWStats project via Paypal: address@hidden
AWBot (Author) :
CVSChangeLogBuilder (Author) :

reply via email to

[Prev in Thread] Current Thread [Next in Thread]