Closed Bug 3375 Opened 26 years ago Closed 26 years ago

Can't set password fields via dom.

Categories

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

x86
Windows NT
defect

Tracking

()

VERIFIED FIXED

People

(Reporter: paul, Assigned: pollmann)

Details

In the following, if you first press the "print values" button, you'll see that the values of the text field and the password field are set to 'hello'. If you then press the "change values" button, you'll see that the password field's value is not changed. <html> <body> <form name="form1"> <input type=button name="but1" value="print values" onclick="printValues()"> <input type=button name="but2" value="change values" onclick="changeValues()"> <BR> <input type=password name="password" value="hello"><BR> <input type=text name="text" value="hello"><BR> </form> <script> var fld = document.form1.elements; var len = fld.length; function printValues() { dump("\nnumber of fields = " + len + "\n"); for (var i = 0; i < len; i++) { dump("\n" + i + ". name = " + fld[i].name + ", value = '" + fld[i].value + "'") } dump("\n"); } function changeValues() { fld[2].value="goodbye"; fld[3].value="goodbye"; } </script> </body> </html>
Assignee: karnaze → pollmann
Eric, please add this test to your DOM tests.
Status: NEW → ASSIGNED
Funny, I just fixed this bug in my tree about five minutes ago. I'll check the fix in later today.
Status: ASSIGNED → RESOLVED
Closed: 26 years ago
Resolution: --- → FIXED
Just checked in a fix.
QA contact needs to be reassigned to white box tester - memo sent to gerardok@netscape.com.
Note for QA: A great set of tests for form element methods and changes to form element attributes is available at: http://blueviper/forms/test.html For example, to test out changes to a passwords "value" attribute, select the PasswordInput form the list box on the left. Enter the desired new value in the "value" input. Click on the "Set" button next to the value input. Click on the "Get" button next to the value input. You can even keep track of the status of these attributes and methods (if they are working or not, and on what platforms). Click on the Status buttons to find out how. This testing tool has been tested and designed for Windows gecko only so far.
QA Contact: 4110 → 4015
Status: RESOLVED → VERIFIED
Working fine now. Marking as verified.
Component: HTML: Form Submission → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.