How to display pop up text on mouse hover?

Viewed 79885

I want to load some content from a DIV tag as pop up text when i hover over an image. When i mouse leave from that image pop should disappear and when i again mouse over image content should show as pop up text. I am using HTML, Jquery, JS for this. It will be very useful if i get a solution using jquery load() method. Let me know ur response.

5 Answers
<p id="icon">Text to hover over</p>
<p id="info" style="display: none">Text to popup</p>

Then, finish it with javascript.

<script>
var e = document.getElementById('icon');
e.onmouseover = function() {
  document.getElementById('info').style.display = 'block';
}
e.onmouseout = function() {
  document.getElementById('info').style.display = 'none';
}
</script>

If you hover over the text, another will popup.

Related