HTML

The Html is an event attribute, which executes a script when the button is clicked. This attribute is supported by all browsers. It is also used to call a function when the button is clicked.

Syntax:

Examples:

Example 1: Following example describes how to use the button tag:

Test it Now

Output:

HTML Button onClick

Browser Support

Element chrome browser Chrome ie browser IE firefox browser Firefox opera browser Opera safari browser Safari
Yes Yes Yes Yes Yes

Next TopicHTML Checkbox Tag




Contact US

Email:[email protected]

HTML Button onClick
10/30