How to use JQuery to load images with callback facility
<p>i use this code to preload images.</p>

<pre><code>var ImagePath='../images/pop.gif';
var _images = [ImagePath];
            $.each(_images, function (e) {
                $(new Image()).load(function () {
                }).attr('src', this);

            });
</code></pre>

<p>i want to attach a callback which will notify when image load completed in client machine. please guide me. thanks</p>

<h2>UPDATE</h2>

<p>just see my below code. i just need to know can i write in this way to notify when each image loading will be completed.</p>

<pre><code>$.each(_images, function (e) {
     $(new Image()).load(function () {
     // image load completed
     }).attr('src', this);
});
</code></pre>

<p>please guide. thanks</p>
