Re[2]: [SMARTY-DEV] Re: Smarty and object support

From: Date: Tue, 17 Dec 2002 19:12:11 +0000
Subject: Re[2]: [SMARTY-DEV] Re: Smarty and object support
References: 1 2 3 4 5  Groups: php.smarty.dev 
Request: Send a blank email to php-smarty-dev+get-430@lists.php.net to get a copy of this message
MO> The problem is you are crossing the line of keeping application logic MO> out of the templates. You really should do something like this: MO> {if $user_is_authorized} MO> ... MO> {/if} MO> ie., let the _application_ deal with constants, calling isAuthorized MO> object, etc. etc, and just assign a simple boolean value for the MO> template. This way you have complete control over the application logic MO> _outside_ the template, and the template syntax is kept clean and MO> concise. complete +100% for this one... What about writing a set of functions that would perform the calls for you ? Maybe it would be better... Bertrand

« previous php.smarty.dev (#430) next »