Closed Bug 225565 Opened 22 years ago Closed 22 years ago

[FIX]Browser ignores form fields with input type "article"

Categories

(Core :: DOM: UI Events & Focus Handling, defect, P2)

defect

Tracking

()

RESOLVED FIXED
mozilla1.6beta

People

(Reporter: waynegwoods, Assigned: bzbarsky)

References

()

Details

Attachments

(2 files)

User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.6b) Gecko/20031111 Firebird/0.7+ Build Identifier: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.6b) Gecko/20031111 Firebird/0.7+ If the form has a text box that is set to input type of "article" then the browser won't treat it as a proper form element. (I hope I'm using the right terminology here). This becomes obvious on the page http://203.166.10.94/overdrive.htm If you fill out the competition form and try to "Submit your guess" on Seamonkey or Firebird, it tells you that you haven't answererd "question 4_4", which is the "Daytime Phone Number:"field. Also, if you use the tab key to switch between fields, it works for the other fields, but skips the phone number field entirely and goes back to the location bar. The phone number field has its input type set to "article". I've produced a reduced test case that proves it's the input type that's the problem. I'll submit that as an attachment next. For all I know, "article" might just be a bad input type and Mozilla might be right in ignoring it. However the web page form works fine in both Safari and Internet Explorer, so I thought it was worth reporting. Reproducible: Always Steps to Reproduce: 1.Go to http://203.166.10.94/overdrive.htm 2.Fill out all the fields on the "Overdrive" competition form and click "Submit your guess" Actual Results: It creates a dialog box saying you have to answer question 4_4 Expected Results: Should have submitted the form correctly
Load the attachment in your browser. Use the tab key to switch between fields. You'll note that it ignores the third field, which has an input type of "article". In Safari and IE, it doesn't ignore this field.
Summary: Borwser ignores form fields with input type "article" → Browser ignores form fields with input type "article"
What's this input type ? The standard types defined in HTML 4.01 and XTHML 1.0 are text, password, checkbox, radio, submit, reset, file, hidden, image and button. http://www.w3.org/TR/html4/interact/forms.html#input-control-types
Then I guess it may be Mozilla just ignoring a bad type then. I'm not a HTML coder.. I just submitted it because it worked in the other two browsers. Thanks :)
I'm not sure the error is due to the type attribute. Even with a wrong type an input elements works like a "text" field and the value is submitted properly.
Confirming bug. This is due to code in the ESM that relies on the type attribute instead of the actual form control type...
Assignee: general → events
Status: UNCONFIRMED → NEW
Component: Browser-General → Event Handling
Ever confirmed: true
QA Contact: general → ian
Attached patch Proposed fixSplinter Review
Attachment #135415 - Flags: superreview?(peterv)
Attachment #135415 - Flags: review?(peterv)
I should just take this. Note that to reproduce "buttons, radio buttons..." needs to be unchecked in your keyboard nav preferences (default setting on Mac, which is why Wayne is seeing the problem).
Assignee: events → bz-vacation
OS: MacOS X → All
Priority: -- → P2
Hardware: Macintosh → All
Summary: Browser ignores form fields with input type "article" → [FIX]Browser ignores form fields with input type "article"
Target Milestone: --- → mozilla1.6beta
Comment on attachment 135415 [details] [diff] [review] Proposed fix I bet there's other places that do this :-/.
Attachment #135415 - Flags: superreview?(peterv)
Attachment #135415 - Flags: superreview+
Attachment #135415 - Flags: review?(peterv)
Attachment #135415 - Flags: review+
Actually, the only place lxr shows offhand that uses GetType(string) is in wallet, which probably can't access nsIFormControl anyway. Patch checked in.
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
Wow, I report a bug, go to sleep, wake up and it's fixed. Thanks Boris! :) Yeah, that keyboard nav. preference was switched off (must be by default). In Firebird I can't even find an equivalent pref to switch on.
Well, peterv's lightning-fast review helped. ;)
OK, thanks Peter, too, then :)
Confirmed fixed on Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.6b) Gecko/20031114 Firebird/0.7+ . Thanks again, guys!
Component: Event Handling → User events and focus handling
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: