[jQuery] Removing Parent Node

[jQuery] Removing Parent Node

Hi,
I have a node list this:
<span style="font-family: courier new,monospace;"><span>
abcd
</span><span style="font-family: courier new,monospace;">    <span class="a">efgh</span>
</span><span style="font-family: courier new,monospace;">    <span class="a">ijkl</span>
</span><span style="font-family: courier new,monospace;">    <span class="a">mnop</span>
</span><span style="font-family: courier new,monospace;"></span><span style="font-family: courier new,monospace;">qrst
</span>
</span>Now, how can I remove all internal spans to have a single (now parent) span holding all letters, having a jQuery object which contains all
span.a elements.
I tried this but not working:
<span style="font-family: courier new,monospace;">$("span.a")</span><span style="font-family: courier new,monospace;">.each(function() {
    th = $(this);
    th.parent().html(th.siblings().eq(0).html + th.text() + </span><span style="font-family: courier new,monospace;">th.siblings().eq(1).html()</span><span style="font-family: courier new,monospace;">);
}<br style="font-family: courier new,monospace;">
</span>
The result should be something like this: <span style="font-family: courier new,monospace;"><span>abcd efgh ijkl mnop qrst</span></span>
Thanks.
_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/