HREF tag and JavaScript

by Nik Robinson <Nikki.Lee.Robinson(at)brunel.ac.uk>

 Date:  Fri, 5 Nov 1999 09:51:36 -0000
 To:  HWG-Basics <hwg-basics(at)hwg.org>
  todo: View Thread, Original
Hi folks, thanks in advance, here's my prob:

I have a JavaScript to open a new window when an image link is clicked!
However the HREF tag at the moment looks like below:

<a href="mypage.html" onClick="winOpen"><img src="pic.gif"></a>

What I really want to do is to be able to put a blank reference term in so
that the parent page remains where it is and unchanged!

I know you can do this using the following code, but I was sure there was a
cleaner way with something like <.A HREF="#" onClick......> etc.

<a href="javascript:winOpen('http://mypage.com')";>Open Page</a>

Thanks again,

Nik Robinson

Chain (Internet Solutions)
***********************************
E-mail: chain-is(at)iname.com

HTML: hwg-basics mailing list archives, maintained by Webmasters @ IWA