Edit Code in left box and click Show Results button to see the result. | Home
<html> <!-- Mirrored from www.tutorialspoint.com/cgi-bin/practice.cgi?file=prototype_184.1 by HTTrack Website Copier/3.x [XR&CO'2010], Thu, 01 Sep 2011 14:50:08 GMT --> <!-- Added by HTTrack --><meta http-equiv="content-type" content="text/html;charset=UTF-8"><!-- /Added by HTTrack --> <head> <title>Prototype examples</title> <script type="text/javascript" src="../javascript/prototype.js"> </script> <script> // Register event 'click' and associated call back. Event.observe(document, 'click', respondToClick); // Callback function to handle the event. function respondToClick(event) { alert("You pressed the button...." ); } </script> </head> <body> <p id="note">Click anywhere to see the result.</p> <p id="para1">This is paragraph 1</p> <p id="para2">This is paragraph 2</p> <div id="division"> This is divsion. </div> </body> <!-- Mirrored from www.tutorialspoint.com/cgi-bin/practice.cgi?file=prototype_184.1 by HTTrack Website Copier/3.x [XR&CO'2010], Thu, 01 Sep 2011 14:50:08 GMT --> <!-- Added by HTTrack --><meta http-equiv="content-type" content="text/html;charset=UTF-8"><!-- /Added by HTTrack --> </html> |