Rollover Text - Hide and Show | JavaScriptSource

Rollover Text - Hide and Show

JavaScriptSource Staff Nov 7, 2007


Use this script to provide tooltips, FAQs, and other information. The tip is shown when the mouse rolls over the title. You can use any valid HTML element, even links.

The World Wide Web Consortium
Develops interoperable technologies (specifications, guidelines, software, and tools) to lead the Web to its full potential.
Unobtrusive JavaScript
The separation of JavaScript functionality (the "behavior layer") from a Web page's structure/content and presentation layers
Unrelated stuff (no link)
Ma quande lingues coalesce, li grammatica del resultant lingue es plu simplic e regulari quam ti del coalescent lingues. Li nov lingua franca va esser plu simplic e regulari quam li existent Europan lingues. It va esser tam simplic quam Occidental.


Source Code

Paste this source code into the designated areas.

External file

Paste this code into an external JavaScript file named: rolloverText.js


Paste this code into your external CSS file or in the <style> section within the HEAD section of your HTML document.


Paste this code into the HEAD section of your HTML document.


Paste this code into the BODY section of your HTML document

Leave a Response


I can assure you Josh, it's not "stolen code". If you look under the "Notes" tab, you will see the link to the forum where it came from, and there you will find an explanation of what it was created for. You can also ask other questions there, if you desire.[br /][br /]We don't provide a detailed explanation with each script. That's for either you to learn yourself or you can always ask how it works over on the [a href=""]JavaScript Forum[/a].

Lee Nov 15, 2007

Can you explain exactly how this works or provide a link to an explanation? There's very little information here, yet it's the first site that comes up. It seems to be just a big junkyard of stolen code with no explanations or knowledge of how JS works.

Josh Nov 14, 2007

Due to the limitations of these comments, you will need to submit your question to the [a href=""]JavaScript Forum[/a] for further help.

Lee Nov 13, 2007

Hi,[br /][br /]I am new at JavaScript and this is the first program I tried in this language. Your rollover text hide and show worked perfectly. I however tried the external css file and it would not work for me until I wrote a path for it to find in the external file. This notation I did not find in your source code, so I thought I would drop you a line. As I said previously, I am new and may have missed something in your explanation.[br /][br /]Sincerely[br /][br /]James Andrews

James Andrews Nov 11, 2007

I figured out how to make the text, but I want to know how to make it so that it does the rollover thing, I can't figure it out. Can you tell me how?[br /][br /]-Eric

Eric K. Nov 8, 2007