Re: [SMARTY] Using $HTTP_POST_VARS for $smarty.post...

From: Date: Wed, 12 Mar 2003 16:17:11 +0000
Subject: Re: [SMARTY] Using $HTTP_POST_VARS for $smarty.post...
References: 1 2 3 4 5 6 7  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-8581@lists.php.net to get a copy of this message
On Wed, Mar 12, 2003 at 04:46:49PM +0100, Joscha Feth wrote: > Paul Lockaby wrote: > > Joscha Feth wrote: > >> Paul Lockaby wrote: > >> > >>> Try this: $HTTP_POST_VARS =& $_POST > >> > >> > >> I know - just try it and you will see it does not work! > >> > > > > Actually, I did just try that and it did work. Are you sure that > > you're including the ampersand (&) after the equal sign (=)? > > I am not saying the code you posted does not work, it is just I use this > function on my $_* arrays > http://dev.feth.com/PHP/my_magic_quotes.phps > and if I use =& Smarty seems to ignore that, because in the compiled > template no reference is used. i tested, and don't have any problems: $HTTP_POST_VARS =& $_POST; $_POST = my_magic_quotes($_POST,false); $_POST['foo'] = 'bla'; and in the template {$smarty.get.foo} has the correct 'bla'. > greets, > Joscha > > > > -- > Smarty General Mailing List (http://smarty.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php -- c't: Eine weniger gelesene Zeitschrift. OLG Düsseldorf: AZ 20 U 78/98

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