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'
}).appendTo('body');
}
$(this).css({'z-index': '6000', 'position': 'relative'}).closest('#postbit-ad').css('z-index', 6000);
$('#ad-overlay').show();
});
$(document).on('mouseleave', '#div-gpt-ad-1321481451196-0', function(event) {
$('#ad-overlay').hide();
$(this).css('z-index', '1005');
});
$(document).on('mouseleave', '#div-gpt-ad-1321481451196-2, #div-gpt-ad-1321481451196-3', function(event) {
$('#ad-overlay').hide();
$(this).css('z-index', 'auto').closest('#postbit-ad').css('z-index', 'auto');
});