Set config file from php?
| From: | Ivan Voras | Date: | Thu, 09 May 2002 12:52:44 +0000 |
| Subject: | Set config file from php? | ||
| Groups: | php.smarty.general | ||
| Request: | Send a blank email to php-smarty-general+get-4109@lists.php.net to get a copy of this message | ||
I am looking for a nice way to specify config file for Smarty templates from
PHP.
I use config files for color themes and I would like to be able to just
specify a different config file when the user changes the theme WITHOUT
having to insert the required smarty command in each and every template.
I expect something like:
$smarty = new Smarty();
$smarty->loadConfig ($currentconfig)
I did a workaround, involving modifying Smarty_compiler to insert the
hard-coded required output, but it is very messy and I need to update it
when new versions of Smarty come out.
--
--
Ashes to ashes, DOS to DOS
ivoras @ fer.hr