1. Button Object
- Button object represents a clickable button in an HTML form.
- It is used to activate a JavaScript when a user clicks on it.
<input type= “button”>
Button Object Method
| Method | Description |
|---|---|
| click() | It simulates the mouse click on the button but don't mix it up with onClick event handler. |
2. Reset Object
- Reset object represents a reset button in an HTML form.
- When clicking on a reset button, it resets all the controls within the form to their default values.
<input type= “reset”>
Reset Object Properties
| Property | Description |
|---|---|
| Length | It returns the number of options in a dropdown list. |
| selectedIndex | It sets or returns the index of the selected option in a dropdown list. |
| Type | It returns a type of form element. |
| name | It returns the name of the selection list. |
3. Submit Object
- Submit object represents a submit button in an HTML form.
- It sends the user input in the form to the server.
- When clicking on a submit button, it fires onSubmit event.
<input type= “submit”>
Submit Object Properties
| Property | Description |
|---|---|
| Length | It returns the number of options in a dropdown list. |
| selectedIndex | It sets or returns the index of the selected option in a dropdown list. |
| Type | It returns a type of form element. |
| name | It returns the name of the selection list. |


