HTML anchor tag with Javascript onclick event
On using Google I found that they are using onclick events in anchor tags. In more option in google header part, it looks like normal a tag, but onclicking it doesn't get redirected but opened a menu. Normally when using <a href='more.php' onclick='show_more_menu()'>More >>></a> It usually goes to 'more.php' without firing show_more_menu() , but I have show a menu in that page itself. How to do like google ? TJHeuvel If your onclick function returns false the default browser behaviour is cancelled. As such: <a href='http://www.google.com' onclick='return check()'>check</a> <script type='text