If a <FORM NAME="ABCD"> tag is present in the document, then there will be a property of the document object called document.ABCD, named after the form. This means you can access the form object directly by name.
If there are several different forms, they will each have a named property according to their names.
This is not supported in the same way on MSIE.
Be careful not to use the same name more than once. Properties must be created according to the name HTML tag attribute in the <FORM> tag. If there are two <FORM NAME="ABCD"> tags, there will only be one ABCD property but you cannot be sure which one of the two forms will be present in it. The individual forms will still be reachable via the forms[] array however.
See also: | Document object, Form object, NAME="..." |
Prev | Home | Next |
Document object | Up | Document.activeElement |
JavaScript Programmer's Reference, Cliff Wootton Wrox Press (www.wrox.com) Join the Wrox JavaScript forum at p2p.wrox.com Please report problems to support@wrox.com © 2001 Wrox Press. All Rights Reserved. Terms and conditions. |