Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Text rollover displays information

Status
Not open for further replies.

stevozip

IS-IT--Management
Apr 11, 2002
3
US
Hi. My question is this: I have a set of links on a page. When the visitor rolls his cursor over the link, I want a little bit of info to pop up to the right of the list of links. I'd rather not use a tool tip, as this means focusing the mouse for a longer period of time. (What can I say? I'm anal. :) Anyways, I would like the information to be displayed in a table, or it could be displayed using the div tag. I'll give an example. When the user rolls his mouse over the link to the Google web site, to the right they will see text that says something like, "The best search engine in the world." Thanks for your help.

Stevozip
 
If you use div's then you can set a style up to show or hide them based on the mouseover.

onMouseover="divName.style.visibility='visible'"
onMouseout="divNmae.style.visibility='hidden'"

of course NN has a slightly diffrent method of showing and hiding so you could use the same method to place the div using absolute and relative positioning.

I hope that helps
Roj
 
Thanks for the info. My knowledge of Javascript is slim to none, so I was wondering, could you give me the actual code to do it? I know that sounds lazy on my part. If I really applied myself I could do it. Thanks, though, for what you gave me.
 
This should do for IE, also I used spans so that they stay on the same line. Div's would move it below the link.

<body>
<a href=&quot; onMouseover=&quot;googleSpan.style.visibility='visible'&quot; onMouseout=&quot;googleSpan.style.visibility='hidden'&quot;>
Google.com</a>&nbsp;&nbsp;<span name=&quot;googleSpan&quot; id=&quot;googleSpan&quot; style=&quot;visibility:hidden&quot;>The Best Search Engine in the World</span>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top