Tryit Editor v1.4

<html> <head> <script type="text/javascript"> function nameon() { document.getElementById('h2text').innerHTML="WELCOME!"; } function nameout() { document.getElementById('h2text').innerHTML="How are you today?"; } </script> </head> <body> <h2 id="h2text" onmouseout="nameout()" onmouseover="nameon()"> Mouse over this text!</h2> </body> </html> | Your Result:
Edit the code above and click to see the result. | W3Schools.com - Try it yourself