Re: [SMARTY] generating php
| From: | Ivo Jansch | Date: | Mon, 10 Jun 2002 07:18:21 +0000 |
| Subject: | Re: [SMARTY] generating php | ||
| References: | 1 2 3 4 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-4716@lists.php.net to get a copy of this message | ||
Hi,
Travis Low wrote:
doing MORE than just replacing strings in a file. For example, I could ask the user if they wanted to disable this or enable that, and it would be handled with Smarty if statements that would emit this or that PHP code. Make sense?So you want to be able to do something like this: install("myapp", {$mypath}); I see no sense whatsoever for doing this in Smarty. You would have to: 1) assign the variable to smarty 2) parse the php file through Smarty 3) run the parsed php code Why not do: install("myapp", $config_path); or something like this? Since you can't get around step 1 in the above example, SOMEWHERE you have to assign the value to a variable. Might as well directly be $config_path then. And php if statements are less overhead than smarty if statements. (Because of the compilation step) Greetings, Ivo -- Ivo Jansch <ivo@ibuildings.nl> ibuildings.nl BV - information technology http://www.ibuildings.nl