I just finished creating a simple jQuery gallery with some fade transitions, as shown here here . Everything works fine in all browsers - except that "image pre-loading" does not work the first time it is loaded into FireFox (it works in all other browsers). Images remain at 0% opacity in firefox. I do not know why.
Here is the preload code.
$(document).ready(function(){
$('img').load(function() {
$(this).animate({opacity : 1.0}, 1000);
$('#headshots img').eq(3).css({'padding-right' : '0'});
$('#ports img').eq(3).css({'padding-right' : '0'});
$('#ports img').eq(7).css({'padding-right' : '0'});
});
});
Thanks in advance for your help.
source
share