Click to See Complete Forum and Search --> : PHP,Apache and windows


Anon
07-02-2002, 04:00 PM
I've discovered that under XP and 2000 variables dont seemed to be passed in GET and POST's properly. For example with "thing.php?foo=here" there is no $foo variable defined with the script thing.php. The same thing happens with POST but interestingly $HTTP_POST_VARS[foo] does contain the posted data. I've never run into this before and it only seems to be on these 2 platforms. Anyone got any ideas how to sort it out. I read something in the apache manual about configuring it to detect scripts as posting to a standard file has no meaning but this didn't seem to help. Any help is greatly appreciated.

Anon
07-03-2002, 07:36 AM
This is just normal.

as of php 4.2.0 and above get and post variables
are no longer registered in the global scope.

You can change this behavious in php.ini.
But it is recommended to fix ur scripts to use
_GET[] and _POST[]

yves

Anon
07-03-2002, 02:18 PM
Indeed, try working at your code.
Secondly, if you want it, just do this in your php.ini:

register_globals = On

Anon
07-09-2002, 12:07 PM
Cheers for your help, I've modified my code to take this into account. Thanks