PDA

View Full Version : Image w/ description tooltip, IExplorer



Contralor
09-09-2005, 03:18 AM
Script: Image w/ description tooltip
http://dynamicdrive.com/dynamicindex4/imagetooltip.htm

When I use this script in Firefox (with a long list of images/links), it works just fine:
The description table follows the mouse without a problem and very smoothly.
http://img359.imageshack.us/img359/61/ff6wk.th.gif (http://img359.imageshack.us/my.php?image=ff6wk.gif)

But when I display the same page in IExplorer, only with the first images/links the description table follows the mouse, then it just stays in the upper part of the page (and if I continue to scroll down, the table is not visible anymore because, well, like I just said, the table stays up there).
http://img359.imageshack.us/img359/3752/ie1oi.th.gif (http://img359.imageshack.us/my.php?image=ie1oi.gif)

Is this fixable? :confused: I just read in some threads that there are bugs where the scripts run just fine on a browser (but no so fine on others, so I'm guessing this is a case like that). Thanks in advance for your help. :)

jscheuer1
09-10-2005, 07:12 AM
The script needs to be updated. Change every instance of:

document.body

to:

iecompattest()

Then add this function just above the credit:


function iecompattest(){
return (document.compatMode && document.compatMode.indexOf("CSS")!=-1)? document.documentElement : document.body
}

Contralor
09-16-2005, 08:27 AM
A little late but I just haven't had the time to reply because of school...

Thanks jscheuer1, it worked perfectly... :D