Re: [SMARTY] Using $HTTP_POST_VARS for $smarty.post...
| From: | Joscha Feth | Date: | Wed, 12 Mar 2003 18:27:10 +0000 |
| Subject: | Re: [SMARTY] Using $HTTP_POST_VARS for $smarty.post... | ||
| References: | 1 2 3 4 5 6 7 8 | Groups: | php.smarty.general |
| Request: | Send a blank email to php-smarty-general+get-8585@lists.php.net to get a copy of this message | ||
Messju Mohr wrote:
> 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'.
I have the problem!!
if I change it like this:
$_GET = my_magic_quotes($_GET,false);
global $HTTP_GET_VARS;
$HTTP_GET_VARS = &$_GET;
it does not work, but if I do:
$_GET = my_magic_quotes($_GET,false);
$GLOBALS["HTTP_GET_VARS"] = &$_GET;
it works...I guess it has something to do with Smarty generating its own
´request array, as in PHP 4.06 no $_REQUEST existed it merges all
$GLOBALS["HTTP_*_VARS"] together - it works now!
greets,
Joscha