Input Button form Property
Definition and Usage
form
The property returns a reference to the form containing the input button.
This property returns the form object on success.
Note:This property is read-only.
Example
Return the id of the form containing the <input type="button"> element:
var x = document.getElementById("myBtn").form.id;
Syntaks
buttonObject.form
Tekniske detaljer
Returværdi: | Henvisning til formularelementer, der indeholder en input-knap. Hvis input-knappen ikke er i formularen, returneres null . |
---|
Browserstøtte
Chrome | Edge | Firefox | Safari | Opera |
---|---|---|---|---|
Chrome | Edge | Firefox | Safari | Opera |
Support | Support | Support | Support | Support |