Jump to Real's How-to Main page

Call javascript from HREF

Method 1
If Javascript is disabled then an error is displayed...
<A HREF="javascript:myFunction()">
    Click here for Javascript action!</A>    
Method 2
If Javascript is disabled then a special page is displayed to warn the user...
<A HREF="nojavascripthere.html" 
   onClick="myFunction(); return false">
      Click here for Javascript action!
</A>    

If you find this article useful, consider making a small donation
to show your supportfor this Web site and its content.

Written and compiled by Réal Gagnon ©1998-2005
[ home ]