package js.html
extends Element › DOMElement › Node › EventTarget
Available on js
The HTMLFormElement interface represents a form element in the DOM; it allows access to and in some cases modification of aspects of the form, as well as access to its component elements.
Documentation HTMLFormElement by Mozilla Contributors, licensed under CC-BY-SA 2.5.
See also:
acceptCharset:StringA DOMString reflecting the value of the form's accept-charset HTML attribute, representing the character encoding that the server accepts.
action:StringA DOMString reflecting the value of the form's action HTML attribute, containing the URI of a program that processes the information submitted by the form.
autocomplete:StringA DOMString reflecting the value of the form's autocomplete HTML attribute, indicating whether the controls in this form can have their values automatically populated by the browser.
read onlyelements:HTMLCollectionA HTMLFormControlsCollection holding all form controls belonging to this form element.
encoding:StringA DOMString reflecting the value of the form's enctype HTML attribute, indicating the type of content that is used to transmit the form to the server. Only specified values can be set. The two properties are synonyms.
enctype:StringA DOMString reflecting the value of the form's enctype HTML attribute, indicating the type of content that is used to transmit the form to the server. Only specified values can be set. The two properties are synonyms.
read onlylength:IntA long reflecting the number of controls in the form.
method:StringA DOMString reflecting the value of the form's method HTML attribute, indicating the HTTP method used to submit the form. Only specified values can be set.
name:StringA DOMString reflecting the value of the form's name HTML attribute, containing the name of the form.
noValidate:BoolA Boolean reflecting the value of the form's novalidate HTML attribute, indicating whether the form should not be validated.
target:StringA DOMString reflecting the value of the form's target HTML attribute, indicating where to display the results received from submitting the form.
checkValidity():BoolReturns true if the element's child controls are subject to constraint validation and satisfy those contraints; returns false if some controls do not satisfy their constraints. Fires an event named invalid at any control that does not satisfy its constraints; such controls are considered invalid if the event is not canceled. It is up to the programmer to decide how to respond to false.
reportValidity():BoolReturns true if the element's child controls satisfy their validation constraints. When false is returned, cancelable invalid events are fired for each invalid child and validation problems are reported to the user.
reset():VoidResets the form to its initial state.
submit():VoidSubmits the form to the server.
Throws:
null |
DOMError |
|---|
© 2005–2020 Haxe Foundation
Licensed under a MIT license.
https://api.haxe.org/js/html/FormElement.html