Example 3 - a button event handler.


The code for the button is:

           <input type="button"
               name="btnGreet"
               value="Click me"
               onclick=" alert('Hi!') " >