Another approach you can take is: var table = $('<table><tr><td><table id="rt0"></td></tr></table></td></tr></table>') .appendTo( parent ) .find('table');
This creates the HTML and then appends it to the parent. Since you created a jQuery object with that fragment, calling find will locate the inner table. Cheers, - Jonathan On Tue, Apr 7, 2009 at 4:38 AM, miniswi...@gmail.com <miniswi...@gmail.com>wrote: > > hi there, see next example: > > parent.append("<table><tr><td><table id=\"rt0\"/></td></tr></table>"); > table = $("#rt0"); > > is it possible to reference the inside table directly without using > the id to select it? >