Saturday, February 27, 2010

PHP Form Not Working in Internet Explorer (IE)

Posted on 7:19:00 PM by Sivaguru Sivasithan

What happens is that fill out the form click submit and the form page is returned totally blanked, however works just fine if Firefox etc. Now are you using an IMAGE instead of the default gray submit button? YES then BINGO you are probably checking in your code to see if the submit button has been pressed and you didn't know that IE as usual does it differently. IE only returns the X,Y co-ordinates of where you clicked on the Image Button, it appends _x and _y to the submit button name. So say the button is called submit_button

So IE returns submit_button_x,submit_button_y

While FF returns submit_button AND submit_button_x,submit_button_y


So Browser proof PHP Code :

if( isset( $_REQUEST["submit_button"] ) or isset( $_REQUEST["submit_button_x"] ) )

This has caught me out several times!!

No Response to "PHP Form Not Working in Internet Explorer (IE)"

Leave A Reply