onchange handler for selects will fire even if *no* change occurs

VERIFIED DUPLICATE of bug 70094

Status

()

Core
Layout: Form Controls
VERIFIED DUPLICATE of bug 70094
17 years ago
17 years ago

People

(Reporter: John Morrison, Assigned: rods (gone))

Tracking

({dom0})

Trunk
x86
Windows 2000
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

17 years ago
Overview Description: 

  The onchange handler for a select (list box) will be fired 
  whether any change is made to the selection or not. In other
  words, if a user just touches a select with this handler, 
  they will submit the form (which is not good).

  (Looked for a dup, figuring there must be one, but couldn't see one.)

Steps to Reproduce: 
1) Load the attachment
2 [details] [diff] [review]) click on the select control, then click in the content area
   to roll up the list, being sure not to alter the current 
   selected <option>

Actual Results:   Form submits
Expected Results: handler should not be triggered in this case

Reproducibility: 100%

Build Date & Platform Bug Found: 2001050212 & 2001042509 trunk win2k

Additional Information: 

Test case

<form action="http://www.mozilla.org/bogo-request" method=get>
  <select size="1" name="GoBox"
      onChange="this.form.submit()">
   <option value="21">Programs & Services
   <option value="22">Travel Assistance
   <option value="23">Airport & Fleet Information
   <option value="24">Alliances
   <option value="25">Inflight Services & Features
  </select>
</form>
(Reporter)

Comment 1

17 years ago
Created attachment 33328 [details]
test case; simple select control with onchange handler
(Reporter)

Comment 2

17 years ago
nsbeta1, correctness, dom0 -- seems like something that should be fixed before
the next release.
Keywords: correctness, dom0, nsbeta1

Comment 3

17 years ago
this is a dup of bug 70094 ...or the other way around

Jake

Comment 4

17 years ago
Duping 

*** This bug has been marked as a duplicate of 70094 ***
Status: NEW → RESOLVED
Last Resolved: 17 years ago
Resolution: --- → DUPLICATE

Comment 5

17 years ago
verifying dupe
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.