[Javascript] formName?
Andrew Gibson
andyg at ihug.co.nz
Thu May 2 21:33:56 CDT 2002
How about:
var f=document.forms['choices']
or
var f=document.getElementById['choices']
> I am using IE 5.5 version 4. I am having a hard time
> working my way down throught the form objects. To
> discover the reason why, I have tried to get the form
> name. I have used the formName property and some other
> useless code to get what the browser thinks the name of
> the form is. Here is the form tag information (<form
> id="choices" name="choices">). Here is some of what I
> have tried:
>
> var Pname = window.parent.name; //worked
> var Wname = window.name; // worked
> var Fname = window.document.formName; and var Fname =
> window.form (with and without .name); and var Fname =
> window.document.forms[0];
>
More information about the Javascript
mailing list