JavaScript: Know when an image is fully loaded
Posted
by Paul Tarjan
on Stack Overflow
See other posts from Stack Overflow
or by Paul Tarjan
Published on 2009-08-10T21:44:50Z
Indexed on
2010/04/23
23:13 UTC
Read the original article
Hit count: 301
If I have a beacon:
<img src="http://example.com/beacon" />
I want a method to be called once the beacon request finishes. Something like:
<script>
$("img.beacon").load(function() {
// do stuff knowing the beacon is done
});
</script>
Is it possible? Is it in jQuery?
© Stack Overflow or respective owner