JavaScript: Know when an image is fully loaded
- by Paul Tarjan
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?