Simply Javascript tooltip code not work in firefox?

hi :slight_smile: i’m looking for help.

I’ve attempted to use the tooltip code from Simply Javascript. It has been working at 100% in both IE and Safari. Recently looked at it with Firefox 3.6.12 and when i try to view the tooltips by hovering over one of the links the browser resets the page to the top of the screen. :sick: There isn’t anything showing up in Firefox’s Error Console; I’m opening it up before and after being reset to the top of the screen.

It’s my dad’s site http://www.ghbservices.com

Just scroll down and you’ll see the green links. The javascript is in http://www.ghbservices.com/tooltips.js and I’ve tried and failed to find the problem to fix.

It’s this line, the fix for Safari and Opera browsers, that’s causing the Firefox problem.


document.documentElement.style.position = "relative";

I’ll pass this on to customer support, who should have a response for us regarding this issue.

At first appearance, the tooltip appears to work in Firefox when the page is edited so that the page doesn’t have to scroll upwards when the tooltip appears.

Does this help much? Not at this stage, but it’s information that can help us come closer to a solution.

Perhaps someone else knows enough about CSS to come up with a solution.

Wow thank you pmw57! :smiley: I’m so happy that you found out the problem and then knew who to tell to get a fix!! And that’s so wonderful you found that the tooltips work when the page cant scroll up! All the css i know is from the awesome book “HTML UTOPIA: Designing without tables using CSS” but, maybe i could… well hope someone can solve the problem.

pmw57, you’ve helped me so much
thanks :),
matthew

Yes. I want people to know that we need more help to solve this. : )

I’ve also posted a new thread to the CSS forum to see if anyone there can shed some light.

Thread: Book help: Relative causing Firefox to jump to top

Okay, just wanted to check.

If I were you I would remove the fix altogether since it works fine in Opera-10 without it. That gets FF working as well.

Seeing how Safari-2 is a long gone it just looks like a counterproductive fix for this day and age.

It’s working fine in Safari-4+ and Chrome too.

There were enough people contacting Kevin Yank about the issue in the JavascriptLive course that he ended up adding that hack into the course.

Thank you so much Rayzur and pmw57 :D… it’s all working great now! :slight_smile: sigh of releaf :cool: