Handle Missing Image Errors with jQuery
// Hide the image on error $("img").error(function(){ $(this).hide(); }); // Change the image to a missing image $('img').error(function(){ $(this).attr('src', 'no-image.jpg'); });