Closed
Bug 16641
Opened 26 years ago
Closed 26 years ago
onclick does not update form...
Categories
(Core :: DOM: Core & HTML, defect, P3)
Core
DOM: Core & HTML
Tracking
()
People
(Reporter: roland.mainz, Assigned: vidur)
Details
Attachments
(1 file)
|
254 bytes,
text/html
|
Details |
We (eg. Ralf Schweiger) tried to get the following working under Mozilla 5 M10,
but it seems that it does not produce the correct results.
IE 5 does update the form radio if the matching form button is pressed.
(BTW: NS4.7 failes, too)
Any idea what's goig wrong here ?
Why does IE5 work - and Moz. noz ? :-(
testcase01.html:
-- snip --
<html>
<body>
<form>
<input type="radio" name="x">
<input type="button" value="ralf" onclick="x[0].clicked=true">
<input type="radio" name="x">
<input type="button" value="roland" onclick="x[1].clicked=true">
</form>
</body>
</html>
-- snip --
| Reporter | ||
Comment 1•26 years ago
|
||
| Reporter | ||
Comment 2•26 years ago
|
||
Created attachment "testcase01.html".
Added CC for Ralf.
| Reporter | ||
Comment 3•26 years ago
|
||
Created attachment "testcase01.html".
Added CC for Ralf.
| Reporter | ||
Comment 4•26 years ago
|
||
Mhhh, something is going wrong with the CC field - it says the email isn't
valid, but I cut&cpoied it from the X500 (and Ralf is alive =:-)
email (manually for now): Ralf.Schweiger@informatik.med.uni-giessen.de
Updated•26 years ago
|
Assignee: mccabe → vidur
Component: Javascript Engine → DOM Level 0
Comment 5•26 years ago
|
||
Reassigning to the DOM component This looks a little like it could be a dup of
15133.
Comment 6•26 years ago
|
||
The original testcase uses "x[0].clicked=true". There's no 'clicked' attribute
for an HTML Input element -- the boolean 'checked' determines whether a Checkbox
or Radio element is checked.
So the testcase should perhaps be:
<html>
<body>
<form>
<input type="radio" name="x">
<input type="button" value="ralf" onClick="x[0].checked=true">
<input type="radio" name="x">
<input type="button" value="roland" onClick="x[1].checked=true">
</form>
</body>
</html>
which works fine in Netscape 4.7, but writes
JavaScript Error: ReferenceError: x is not defined
to stderr when either of the buttons is clicked under Linux (RH6.0) build
1999102010 ... but I'd have to defer to the DOM Masters as to whether 'x' is
actually in scope in the onClick handler. It might be more correct to say
<html>
<body>
<form>
<input type="radio" name="x">
<input type="button" value="ralf" onClick="this.form.x[0].checked=true">
<input type="radio" name="x">
<input type="button" value="roland" onClick="this.form.x[1].checked=true">
</form>
</body>
</html>
instead, but *that* won't work in current mozilla builds, either, producing:
JavaScript Error: TypeError: this.form.x[0] has no properties
because multiple form elements with the same name are not currently being
reflected into an array with that name. See bug 12307 and bug 15361.
| Assignee | ||
Comment 7•26 years ago
|
||
In an attempt to get my bug list in order again, marking all the bugs I have
currently as ASSIGNED.
| Assignee | ||
Updated•26 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 26 years ago
Resolution: --- → DUPLICATE
Updated•26 years ago
|
Status: RESOLVED → VERIFIED
Comment 9•26 years ago
|
||
Dup Verified.
| Comment hidden (Intermittent Failures Robot) |
You need to log in
before you can comment on or make changes to this bug.
Description
•