Doesn't the append function return the appended object?
<p>Assuming <code>this</code> is some existing block level element in the dom and <code>image</code> is <code>http://www.google.com/images/srpr/nav_logo25.png</code> doing the following does not work:</p>

<pre><code>$(this).append('&lt;img&gt;').attr('src', image).load(function() { alert('loaded'); });
</code></pre>

<p>Should it be done as follows?:</p>

<pre><code>$(this).append($('&lt;img&gt;').attr('src', opts.image).load(function() { alert('loaded'); }));
</code></pre>

<p>Or it should be done some other way?</p>
