Code
Execute
<!DOCTYPE html> <html> <head> <title>html tutorial - html5 - html code - html form - In 30Sec by Microsoft Award MVP - | wikitechy onhashchange attribute </title> </head> <body onhashchange="onHashChange()"> <p id="tutorial">Wikitechy Tutorials lear code in wikitechy</p> <a href="#tutorial">Click here to check onhashchange attribute</a> <script> function onHashChange() { alert("onhashchange called!"); } </script> </body> </html>
Result