• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

Event Handlers

The XHTML 1.0 recommendation also allows for several event handlers that can be used to trigger the execution of script code embedded in an XHTML document. Each event handler is tied to a specific event that can occur during a person's use of a browser. When a user submits a form, for example, you can capture that event and launch a field validation script using the onsubmit event handler:

<form action="register.cgi" method="post" onsubmit="return validate();">


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint