RE: [PHP] Re: Migration from register_globals=on to register_glob als=off
| From: | Jonathan Wilkes | Date: | Tue, 03 Jun 2003 16:22:17 +0000 |
| Subject: | RE: [PHP] Re: Migration from register_globals=on to register_glob als=off | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-149998@lists.php.net to get a copy of this message | ||
yep I did, sorry about that
-----Original Message-----
From: Leif K-Brooks [mailto:eurleif@buyer-brokerage.com]
Sent: 03 June 2003 17:15
To: Jonathan Wilkes
Cc: 'Øystein Håland'; php-general@lists.php.net
Subject: Re: [PHP] Re: Migration from register_globals=on to
register_glob als=off
Uh, I think you mean
echo $_POST['path'];
and
echo $_GET['path'];
Jonathan Wilkes wrote:
>Hi,
>
>What he means is that with "register_globals=off" you cannot do this:
>
> echo $path
>
>you need to do this (if the variable is sent by "POST" action)
>
> echo _POST('path')
>
>and through "GET"
>
> echo _GET('path')
>
>-----Original Message-----
>From: Xystein Heland [mailto:ha@ematte.se]
>Sent: 03 June 2003 17:02
>To: php-general@lists.php.net
>Subject: [PHP] Re: Migration from register_globals=on to
>register_globals=off
>
>
>I'm not sure what you mean. To give ONE example:
>Earlier I could use this code on top of every page:
>if ($printout != "yeah") { include("header.php"); }
>This code gives an error today. The variable $printout is set if the
visitor
>choose to click on the 'print_page_image', otherwise the variable has no
>value.
>
>"Esteban FernaNdez" <efernandez@tecsol.cl> skrev i meddelandet
>news:20030603154909.78521.qmail@pb1.pair.com...
>
>
>>When you recivied that error ?, in a form ?, if is in a Form just put in
>>
>>
>the
>
>
>>top of .php files this code
>>
>>$HTTP_GET_VARS["variable2"];
>>$HTTP_GET_VARS["variable3"];
>>
>>Of course if you send with other method (post) change the GET for POST
>>
>>$HTTP_POS_VARS["variable2"];
>>$HTTP_POS_VARS["variable3"];
>>
>>Regards.
>>
>>Esteban.
>>
>>
>>
>>"XYstein HeLand" <ha@ematte.se> escribis en el mensaje
>>news:20030603150831.24991.qmail@pb1.pair.com...
>>
>>
>>>None of my old scripts worx nowadays and the most common error message
>>>
>>>
>is
>
>
>>>'undefined variable'. What is the best/simplest way to work around this
>>>situation?
>>>if !isset($myvar) {
>>>do this
>>>blah blah
>>>}
>>>?
>>>
>>>
>>>
>>>
>>
>>
>
>
>
>
>
--
The above message is encrypted with double rot13 encoding. Any unauthorized
attempt to decrypt it will be prosecuted to the full extent of the law.