Hello everyone,
I am running some code in IE 6.0. It seems as though there is a bug
with .js functionality in IE though.
I have the following in an HTML form:
<FORM name="FrmXTest" id="FormTest" method="post">
</FORM>
<FORM name="FrmX1" id="Form2" method="post">
</FORM>
<FORM name="FrmX" id="Form3" method="post" >
....
[many more controls/objects]
....
</FORM>
I would think that the following javascript commands:
alert("forms 0 ->" + document.forms[0]);
Would produce: [object]
alert("forms 0 NAME ->" + document.forms[0].name);
Would produce: FrmXTest
alert("forms 1 ->" + document.forms[1]);
Would produce: [object]
alert("forms 1 NAME ->" + document.forms[1].name);
Would produce: FrmX1
***But*** what I actually get is:
alert("forms 0 ->" + document.forms[0]);
Produces: [object]
alert("forms 0 NAME ->" + document.forms[0].name);
Produces: <blank>
alert("forms 1 ->" + document.forms[1]);
Produces: [object]
alert("forms 1 NAME ->" + document.forms[1].name);
Produces: FrmX1
The name of the form in the 0 spot of the array is "blank" while the
name of the form in the 1 spot of the array is "FrmX1"??? Are things
supposed to work like this or is it some kind of bug?
TIA