jquery $(this) works once inside same function
<pre><code>$('#test img:first').ready(function() {      
    var w = $(this).width();
    console.log(w);     

    $('#test img:first').attr('width', 200);
    //$(this).attr('width', 200);
});
</code></pre>

<p>width of the element is correct
so as setting width via selector
but </p>

<pre><code>$(this).attr('width', 200);
</code></pre>

<p>doesn't work, what am I missing?</p>
