User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.8b3) Gecko/20050712 Firefox/1.0+ Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.8b3) Gecko/20050712 Firefox/1.0+ I am using an input element inside an label element which is linked with an radio button. When I click on the input element the focus is set to the radio button - not to the input element. So I can't enter any values. Reproducible: Always Steps to Reproduce: 1.open attached example 2.click on the input element 3. Actual Results: focus is set to radio button Expected Results: focus should be set to input element
The label has attribute for="IsAvailableDate", so the focus goes to the form element with that id, which happens to be the radio button. When you remove that for attribute, everything should work ok.
Created attachment 197300 [details] Example code producing behavior Snippet of HTML code from Collegeboard.com which produces the bug. Clicking inside the input element moves focus to the radio button and makes it (nearly) impossible to type in the input (text) box.
May be a Gecko bug? Confirmed in both Windows 2000 and Windows XP Pro SP2. This should be labeled as a MAJOR bug, because when it shows up, it's serious. Even though it's technically, and arguably, the fault of whosever HTML it was.
Confirmed in Win XP - Firefox 1.5Beta1
Summary: Using input element inside a label element -> focus for input element gets lost when you click on it → Using input element inside a label element -> focus for input element gets lost when you click in it
i can reproduce this bug with the testcase on Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9a6pre) Gecko/2007060704 Minefield/3.0a6pre - so confirmed
Status: UNCONFIRMED → NEW
Component: General → Event Handling
Ever confirmed: true
Product: Firefox → Core
QA Contact: general → events
Status: NEW → RESOLVED
Last Resolved: 11 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 213519
You need to log in before you can comment on or make changes to this bug.