Do you have the CSS taken care of? I assume that you use the "card" class to hook the CSS to the elements. You could move the "visibility: hidden" to that class from the inline style.
There's probably a more graceful solution available, but this is what popped into my head.
Change the loadimage function from DD to this:
Code:
loadimage:function(link){ //Load image function that gets attached to each link on the page with rel="thumbnail"
if (this.thumbBox.style.visibility == "visible") //if thumbox is visible on the page already
this.closeit() //Hide it first (not doing so causes triggers some positioning bug in Firefox
this.featureImage = link.lastChild.cloneNode(true);
this.featureImage.style.visibility = "visible";
this.centerDiv(this.thumbLoading); //Center and display "loading" div while we set up the image to be shown
while(this.thumbImage.hasChildNodes()){
this.thumbImage.removeChild(this.thumbImage.lastChild);
}
this.thumbImage.appendChild(this.featureImage); //Populate thumbImage div with image (while still hidden)
thumbnailviewer.showthumbBox();
return false;
},
Here's a demo:
HTML Code:
<html>
<head>
<title></title>
<link rel="stylesheet" href="thumbnailviewer.css" type="text/css" />
<script src="thumbnailviewer.js" type="text/javascript">
/***********************************************
* Image Thumbnail Viewer Script- © Dynamic Drive (www.dynamicdrive.com)
* This notice must stay intact for legal use.
* Visit http://www.dynamicdrive.com/ for full source code
***********************************************/
</script>
</head>
<body>
<p><a href="" rel="thumbnail"><img src="thumbnail.gif" style="width: 50px; height: 50px" /><span style="visibility: hidden;" class="card">Blah!</span></a></p>
</body>
</html>
Bookmarks