Re: [SMARTY] Smarty and possibility to parse Javascript-Files?
| From: | Matthias Mohr | Date: | Sun, 09 Mar 2003 22:08:22 +0000 |
| Subject: | Re: [SMARTY] Smarty and possibility to parse Javascript-Files? | ||
| References: | 1 2 3 4 5 6 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-8512@lists.php.net to get a copy of this message | ||
Thanks a lot to Messju and Jason,
I'll give the external "pseudo" javascript-file (via PHP) a try...
... or I live with my workaround, to have the javascript
variables defined in the templates and to ask for them in
the javascript file like that:
-------------------------------------------------------------
if ( !external_variable )
var external_variable="Default";
-------------------------------------------------------------
this enables me to have the javascript file complete and working
and still the possibility to define variables outside.
The only issue is the defaults of that variables - if I change them
I need to change them in two places, the PHP-config (for the
templates) and in the javascript-files.
with regards,
Matthias