PDA

View Full Version : Image w/ description tooltip



Signe
05-27-2005, 07:24 AM
Have a problem and wonder if someone can help.

I want http://www.dynamicdrive.com/dynamicindex4/imagetooltip.htm on a website I rebuild.

It works excelent in Netscape but not in IE. When you scroll down, the picture comes up longer and longer from the arrow so you, at last, not can se it.

You can check a test on www.orks.nu/ny/hastar.html
The page is on swedish, but code is code, links don't work.

:p Thanks!

jscheuer1
05-27-2005, 08:14 AM
This might not fix it but, this:
<div id="tipDiv" style="position:absolute; visibility:hidden; z-index:500"></div>
</div>belongs right above this:
</body>You have many things between them.

Krede
05-27-2005, 04:09 PM
Hi!

I have a similar problem and your solution didn't help me!

It works fine in mozilla but not in IE, I'm talking about the tooltip when holding the mouse over the profile-link, it doesn't seem to follow the mouse as it should.

I could really use some help here.

Thanks in advance :)

The link to the page is: http://sfs.lurmig.dk/echo.php

jscheuer1
05-27-2005, 06:06 PM
It is your doctype declaration that is throwing things off. The script isn't compatible. The script can be made compatible in two steps:

1) There are 8 occurrences of:
document.bodyin the script. Change all 8 to:
iecompattest()

2) At the top of the script, right after the credit:
/*
Image w/ description tooltip- By Dynamic Web Coding (www.dyn-web.com)
Copyright 2002 by Sharon Paine
Visit http://www.dynamicdrive.com for this script
*/put this function:
function iecompattest(){
return (document.compatMode && document.compatMode.indexOf("CSS")!=-1)? document.documentElement : document.body
}so it looks like this:
/*
Image w/ description tooltip- By Dynamic Web Coding (www.dyn-web.com)
Copyright 2002 by Sharon Paine
Visit http://www.dynamicdrive.com for this script
*/

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

/* IMPORTANT: Put script after tooltip div or
put tooltip div just before </BODY>. */That's it.

Krede
05-27-2005, 06:47 PM
Thank you so much :D

Now it's working perfectly

You're a lifesaver =)

Signe
05-27-2005, 10:52 PM
Thanks so very mutch, I'm so happy that it works. :)

:p

ddadmin
05-30-2005, 09:40 PM
Thanks jscheuer1 for the remindar on the doctype issue. Adding this script to the list of "to fix" scripts for doctype.

something4u
07-31-2005, 06:04 PM
hi

i have the problem that the tooltip window is behind other frames...

do you have some ideas for an solution?

thx

ddadmin
07-31-2005, 10:47 PM
something4u, there's no way for this script to display the tooltip across frames unfortunately.

THE_BATMan_Phln
08-12-2005, 01:27 AM
I had the same problem with horizontal scrolling. The fix above worked great!!

THANKS!