View Single Post
Old 09-28-2012, 12:25 AM   PM User | #4
Vytfla
New Coder

 
Join Date: Apr 2012
Posts: 84
Thanks: 4
Thanked 0 Times in 0 Posts
Vytfla is an unknown quantity at this point
Quote:
Originally Posted by fireplace_tea View Post
I like to use JavaScript to tell the browser that when I mouse over the photo I would like to unhide the text. Here is what I would code:

HTML:
<div id="footer-left">
<a href="#"><img src="images/arrow.png" id="myimage" /></a>
</div>
<p id="showme">Top</p>

JAVASCRIPT:
var image = document.getElementById('myimage');
var show = document.getElementById('showme');
image.onmouseover = function(){
show.style.display = "block";
};
image.onmouseout = function(){
show.style.display = "none";
};
Is there no way to do it via CSS only?
Vytfla is offline   Reply With Quote