Article pages on DaniWeb (for those of you who live in the US) have a hover effect (similar to that on our homepage for everybody). It works fine in all browsers except for Firefox. Firefox is just super temperamental: it works a few times and then just mysteriously stops working and I can't figure out why.

Here's my code:

$(document).on('mouseenter', '#div-gpt-ad-1321481451196-0, #div-gpt-ad-1321481451196-2, #div-gpt-ad-1321481451196-3', function(event) {
    if ($('#ad-overlay').length == 0)
        jQuery('<div/>', {
            id: 'ad-overlay'
    $(this).css({'z-index': '6000', 'position': 'relative'}).closest('#postbit-ad').css('z-index', 6000);

$(document).on('mouseleave', '#div-gpt-ad-1321481451196-0', function(event) {
    $(this).css('z-index', '1005');

$(document).on('mouseleave', '#div-gpt-ad-1321481451196-2, #div-gpt-ad-1321481451196-3', function(event) {
    $(this).css('z-index', 'auto').closest('#postbit-ad').css('z-index', 'auto');

Recommended Answers

All 4 Replies

Are you talking about the lightbox effect when you hover over adds? That works fine for me in firefox.

Yes, I am. It works fine on the homepage in Firefox but, both on my mac and pc, it is very temperamental on article pages. If you continuously quickly hover on and off the ads repeatedly, certain ads "break" the effect.

I wonder if mouseover/mouseout has the same behavior in FF.

Erratic behaviour on repetitive user-actions was revealed while testing my JS Spartan (property) Togler, targeting properties on STYLE object. The bug was filed at Bugzilla, (Bug 720129), but because of its manifestation inconsistency, its status remains UNCONFIRMED since.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.