
Return to the HTML Tips
Open Link on Mouse Over
From:
THE INTERNET TUTOR
Thursday, September 26, 2002
by Boogie Jack
Note: In code examples I add a period after each left arrow
bracket so the code can be viewed in all email programs. If
you copy and paste, be sure to remove the periods or it won't
work.
You can have your links open by simply having a user pass
their mouse over a link, it's not necessary to click the
link. You do have to be careful where you use it though.
If you have a lot of links all bunched up together, some-
one could accidently open several windows with different
links at the same time.
I'll leave it up to you to find a useful place for it (and
isn't that sweet of me ;-). The code below shows the link
using text for the link, but you could use an image in place
of the text just as easily. This particular code will open
the link in a new browser window.
<.a href="http://www.boogiejack.com/" onmouseover="window.open
('http://www.boogiejack.com/');">Boogie Jack's Web Depot<./a>
If you want to open a link in the same browser window (still,
with just a mouseover), then use this:
<.a href=""
onmouseover="parent.location='http://www.boogiejack.com'">
Boogie Jack's Web Depot
And that's how this mouse trap works, no cheese required.
[report a broken link by clicking here]






