Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

grantm (164)

grantm
  (email not shown publicly)
http://www.mclean.net.nz/

Just a simple [cpan.org] guy, hacking Perl for fun and profit since way back in the last millenium. You may find me hanging around in the monestary [perlmonks.org].

What am I working on right now? Probably the Sprog project [sourceforge.net].

GnuPG key Fingerprint:
6CA8 2022 5006 70E9 2D66
AE3F 1AF1 A20A 4CC0 0851

Journal of grantm (164)

Monday November 24, 2003
08:04 PM

More IE Wierdness

[ #15992 ]

A while ago, matts wrote in his journal about strange IE behaviour. Coincidentally, at the time I'd just been researching the same area and concluded that IE's behaviour made sense and it was Mozilla that seemed to be misbehaving. I've just been researching this a bit more and thought another datapoint or two might be in order. First a couple of links:

I have now revised my conclusion. I repeatedly encountered statements to the effect that the reason Mozilla behaves the way it does, is for compatibility with IE. This made no sense to me since in my tests the two browsers behaved differently. The thing I was missing was that IE's behaviour depends on how many text entry fields are in the form:

  • IE, one text field: send nothing
  • IE, multiple text fields: send name=value of 'first' button
  • Mozilla, one text field: send name=value of 'first' button
  • Mozilla, multiple text fields: send name=value of 'first' button

Clearly IE's behaviour is bizarrely inconsistent after all. Unfortunately Mozilla's behaviour is also inconsistent since (as Dom pointed out) form.submit() does not cause a button value to be sent. The 'correct' behaviour would seem to be 'only send a button value if a button is actually pressed'. Unfortunately, no one does that (Opera works the same as Mozilla).

So, to sum up:

  1. Even if your submit button has a name, your server-side script can't assume the named parameter will be sent
  2. Even if your script receives a button name+value, you can't assume the user actually clicked that button
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.