Re: [SMARTY] Assign a generic value to any Smarty variable possible ?

From: Date: Mon, 07 Apr 2003 22:08:36 +0000
Subject: Re: [SMARTY] Assign a generic value to any Smarty variable possible ?
References: 1  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-9179@lists.php.net to get a copy of this message
i dont think there is such a function. maybe you can write a prefilter, replacing all "$foo" with "foo". or dont replaces them, assign them to smarty in the prefilter. but it is (very) difficult to know which variable represents an array and which does not. ----- Original Message ----- From: "Luc Saint-Elie" <luc@regardnumerique.com> To: <smarty-general@lists.php.net> Sent: Monday, April 07, 2003 9:29 PM Subject: [SMARTY] Assign a generic value to any Smarty variable possible ? > Hello, > Is there a way to write a Smarty call that says : > "Whatever Smarty variable you find in the template (*.tpl file) assign it > the value $genericvalue" ? > > I know this question could seem strange but I'm writing something that will > allow the user to preview the result (design) of a template, but at the > time of the preview, the template's real content has not yet been defined. > I could force the user to declare the variables he used in the template, > but I'd find more elegant for preview to be able to place generic > non-meaning text to whatever template variable as been set without asking > the user. > > Luc > > > > -- > Smarty General Mailing List (http://smarty.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > >

« previous php.smarty.general (#9179) next »