span id=s>
<table id="tb1" border=1>
<tr><td>aaa</td></tr>
</table>
<table id="tb2" border=1>
<tr><td>bbb</td></tr>
</table>
<table id="tb3" border=1>
<tr><td>ccc</td></tr>
</table>
<table id="tb4" border=1>
<tr><td>ddd</td></tr>
</table>
</span>
<input type=submit onclick="s.appendChild(s.childNodes[0]);">