Closed Bug 142089 Opened 22 years ago Closed 22 years ago

submit type=image submits name as well as x/y

Categories

(Core :: DOM: Core & HTML, defect)

PowerPC
macOS
defect
Not set
minor

Tracking

()

VERIFIED INVALID

People

(Reporter: david, Assigned: john)

References

Details

(Keywords: compat)

This may or not be a bug, but in my experience with other browsers, including
Mozilla until recently, if I created a form submit button like this:

<input type="image" src="/save.gif" border="0" name="save" />

When the form is submitted by clicking the image, the following two fields are
submitted: "save.x" and  "save.y". With Mozilla RC1, however, I've noticed that
"save" also gets submitted. Up to now, and with other browsers, only the first
two were submitted. Mozilla RC1 is the first browser I've noticed was submitting
all three.

Now, this might be construed as a feature, and once I figured out that Mozilla
was doing this, I was able to account for it in my form-handling code. But,
while I'm not altogether familiar with the technical specs for form submission,
it's my understanding that this isn't standard behavior.

But if it is, just ignore this. :-)

Thanks!
to jkeiser.... If this breaks sites, we want to fix it; if it does not, then we
don't care.
Assignee: alexsavulov → jkeiser
Status: UNCONFIRMED → NEW
Ever confirmed: true
Keywords: compat
Yes, feature.  I explicitly added this because it fits the spec better.
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → INVALID
Waiiit, too hasty of me.  It's being submitted even when there's no value?  That
sounds like a bug to me.
Status: RESOLVED → REOPENED
Resolution: INVALID → ---
Um, I dunno, actually. I left the value out of my example to keep it terse. But
I think I always provide a value.

Wait, let me do a quick test...look here:

http://theory.kineticode.com/moztest/

No, it's not submitting the field if there's no value. That's kind of cool. Thanks!
OK, then it's a feature :)  Thanks!
Status: REOPENED → RESOLVED
Closed: 22 years ago22 years ago
Resolution: --- → INVALID
verifying
Status: RESOLVED → VERIFIED
*** Bug 305518 has been marked as a duplicate of this bug. ***
Component: HTML: Form Submission → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.