Here is the problem...I am trying to migrate a few web sites that we have from Linux-->Apache-->PHP-->MySQL to Windows 2000-->IIS 5-->PHP-->MySQL. I have sucessfully installed PHP 4.2 on the Win2k machine and have migrated the sites over. PHP seems to be functioning fine except for one thing. I have a html Form that POSTS data back to itself (index.php) POSTS to index.php. This works fine on the Linux machine but the variables dont get passed on IIS. If I remove the PHP code from index.php and rename index.html, without modifying the form at all, and POST to the original index.php, it works perfect. I am not a PHP expert and did not originally write the code.
Problems with POST on IIS
Hi,
look on your IIS-settings (Home directory / Button "configuration") for app-mappings of files with the php-suffix.
Maybe the verbs for that handling are not set to "all" but just to "GET"
Best regards,
King Louie
I took a look just to make sure but the verbs are set to all. If you have any other suggestions I would appreciate the help.
I'm experiencing the same problem.
Also GET requests fail by the way...
I am also having the exact same problem. I'd love it if somebody could drop me a line when this one is fixed!
Is it by any chance related to the php.ini settings variables_order? It seems like either a Session or Cookie variable may be overwriting your GET - Will only happen if your "Register_Globals" is turned on (bad bad bad) but if you have installed 4.2.x; Register_globals would have been turned OFF by default (unless you have an old php.ini hanging around)- which means the all so (wrongly) convenient $GLOBALS can no longer be used - as the "EGPCS" variables are no longer within that scope! yay...
Hmm... I am also trying to run php 4.2.1 on IIS Win XP. I faced the same problem... I mean I am unable to access GET and POST variables. After spending a looooot of time... I have got a solution... go back to php 4.1.0. Frankly speaking... there is a bug in 4.2.1.
Good Luck
fadee
The only way I've resolved this problem is by editing the php.ini file to:
register_globals = on
which is not at all great if the machine were for live applications. If you're just developing your applications on XP (and not using XP for a live application), maybe this is not such a big deal...