Hey there,
So I've got this .load setup for an image with a .fadeIn() callback, that works just fine. The problem is if I fire the .load twice in a row on the same image, it doesn't get to the callback!
Here's a snippet of the code:
$('#thumbs a').click( function() {
imageSrc = $(this).attr('href').substring(1)+'.jpg'; // grab src, remove hash, add jpeg extension
$('#viewer img').fadeOut('fast', function() { // fade old image out fast, wait until finished before changing src
$('#viewer img').attr('src', (mediumPath+imageSrc)); // change src to new image
$('#viewer a').attr('href', imageSrc);
});
$('#viewer img').load(function(){ // once image is loaded, fade the img back in
$('#viewer img').fadeIn('slow');
});
return false;
});
And you can try it on my website (in progress) here. Just click on a thumbnail on the left twice in a row and the loader.gif doesn't go away, i.e. not getting to .fadeIn().
Note: I believe this is only affecting WebKit Browsers(?)