Button.onFocus : Button : Form JAVASCRIPT TUTORIALS


JAVASCRIPT TUTORIALS » Form » Button »

 

Button.onFocus









Syntax








onFocus="command"



The onFocus event handler is defined in an tag and specifies what to do when the button gains focus.












<html>
    <form name="myForm">
      <input type="button"
             value="Big Button"
             name="myButton"
             onFocus="alert('Focus event occured')">
    </form>
    </html>







HTML code for linking to this page:

Follow Navioo On Twitter

JAVASCRIPT TUTORIALS

 Navioo Form
» Button