A tooltip is out of the question without extensive modification. In fact, the script strips title attributes to prevent that. If the mouse goes over a title attribute, it has gone off of the expanded image, so it will shrink. A separate DOM element tooltip could be used, but it would have to be setup to, when it's moused over, to not trigger the usual onmouseout event of the expanded image.
The method outlined in my demo here:
http://home.comcast.net/~jscheuer1/side/expando/
for the cat image will work though. View its source code to see the important parts which are the style (the important one is highlighted):
Code:
<style type="text/css">
img {
border: none;
vertical-align: top;
}
.shield {
margin-top: 1em;
}
.cat {
margin: 0 0 1em 1.5em;
}
.line {
visibility: hidden;
}
</style>
and in the markup (additions highlighted):
Code:
<div>
<img class="expando cat" src="cat.png" alt="" width=250 height=137
onmouseover="document.getElementById('catline').style.visibility='visible';"
onmouseout="document.getElementById('catline').style.visibility='';">
<span class="line" id="catline"><br>Line of text</span>
</div>
Notice the color coded id and class names. Something similar can be setup for as many expando images as you like. You may use the same class for all the lines, but the id (catline here), must be unique for each expando image.
If you want more help:
Please post a link to a page on your site that contains the problematic code so we can check it out.
Bookmarks