I have a website with images on it. Some of the images are animated GIF images. What I\'ve done is to show a static image of the GIF and on a click event, the actual GIF ima
this would be a solution to larger images Restart an animated GIF from JavaScript without reloading the image
in a nut shell load the image into a javascript variable then change out the src on click
$(function(){
var image = new Image();
image.src='http://rack.3.mshcdn.com/media/ZgkyMDEyLzEwLzE5LzExXzMzXzMzXzE3Nl9maWxlCnAJdGh1bWIJMTIwMHg 5NjAwPg/462b8072';
$('#img').click(function(){
$(this).attr('src',image.src);
});
});
http://jsfiddle.net/GS427/1/
its ugly i couldnt find the right image for the starting but you can see that it starts in the same place every time
You need to divide mouse event to mousedown and mouseup, perform hiding first and showing second or viceversa on mousedown then perform hiding first and showing second or viceversa on up,