The form Object [2|3|I]

The form object reflects an HTML form in JavaScript. Each HTML form in a document is reflected by a distinct instance of the form object.

Properties

  • action— A string value specifying the URL to which the form data is submitted.

  • elements— Array of objects for each form element in the order in which they appear in the form.

  • encoding— String containing the MIME encoding of the form as specified in the enctype attribute.

  • method— A string value containing the method of submission of form data to the server.

  • name— A string value reflecting the name of the form element.

  • target— A string value containing the name of the window to which responses to form submissions are directed.

Methods

  • reset()— Resets the form. (Not 2.)

  • submit()— Submits ...

Get Platinum Edition Using XHTML™, XML, and Java™ 2 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.