jQuery script not working properly on Google Chrome <p>I have the following code that seems to not work in Google Chrome.</p> <pre><code>$("#productImg img").click(function() { var img = $(this).attr("src"); var text = $(this).attr("id"); $("#loader").show(); $("#largeImg img").load(function() { $("#loader").hide(); }).attr("src", img.replace('th_', 'si_')); }); </code></pre> <p>It works fine in Firefox, but doesn't in Chrome. If i click the first image it makes some kind of loop and never hides the <code>#loader</code>. You can test it <a href="http://www.anpilinen.com/index.php?id=beddingSuppliesBlanketPique" rel="nofollow">here</a>.</p> <p>Any help is appreciated!</p>