I can't see anything I'm doing wrong here, but it still won't work. I've tried this:
<code> var span = $('<span>Elem</span>'); span.appendTo(this); </code> but then Firebug says: <code> Node cannot be inserted at the specified point in the hierarchy" code: "3 this.appendChild( elem ); [jquery.js line 238] </code> I'm lost here..