Assigning jQuery Data Property
<p>Good morning folks, just wanted to check if someone can help me with the jQuery data property in a script.</p>

<p>Basically I am using this plugin - <a href="https://github.com/farinspace/jquery.imgpreload" rel="nofollow">https://github.com/farinspace/jquery.imgpreload</a></p>

<p>Its a simple preload plugin.</p>

<p>What I am trying to do is one line 66 just after the src attribute is assigned to the image object - I am trying to put the width and height attribute of that image in its data but its not working.</p>

<p>I am inserting this just after line 66</p>

<pre><code>$.data(this, 'dimensions', { 'width': img.width, 'height': img.height });
</code></pre>

<p>Its giving me a "indefinite recursion" error in the query. </p>

<p>Any clues?</p>
