Button on click event : Button « Form Control « JavaScript DHTML
- JavaScript DHTML
- Form Control
- Button
Button on click event
<HTML>
<BODY>
<A HREF="http://www.java2s.com" onMouseOver="window.alert('over!');">Java2s!</A>
<P>
<FORM>
Phone Number: <INPUT type="text" size="25" onFocus="window.alert('on focus');">
<BR>
Name: <INPUT type="text" size="25" onBlur="window.alert('focus lost');">
<BR>
E-mail Address: <INPUT type="text" size="25">
<P>
<INPUT type="button" value="Click Here." onClick="window.alert('on click')";>
</FORM>
</BODY>
</HTML>
Related examples in the same category