Input Button type eigenschap

Definitie en gebruik

type De eigenschap retourneert welk type formulierelement de invoerknop is.

Voor de invoerknop, deze eigenschap retourneert altijd "button".

Example

Returns which type of form element the input button is:

var x = document.getElementById("myBtn").type;

Try it yourself

Syntax

buttonObject.type

Technical details

Return value: String value, representing the form element type of the input button.

Browser support

Chrome Edge Firefox Safari Opera
Chrome Edge Firefox Safari Opera
Support Support Support Support Support