Extra div in DOM Inspector
- Since I was unsuccessful with the XHR DataSource method of populating
a table, I am trying to work around it by using a Connection object,
and attaching the responseText to a div in the page. This works ok for
the data, but sorting and selection functionality fails after the new
data is attached to the div.
I have looked at the http response and copy-pasted the body text into
the page. The data populates and sorting and selection work fine when
the text is static markup in the page.
I have looked in the eclipse DOM inspector, and found that when the
text is statically attached to the div in the page, there is an extra
TBODY that appears in the DOM tree. The first is a plain
TBODY->TR->TD, the second is
The dynamically inserted table only shows one TBODY node in the DOM
tree, and the TRs and TDs are plain, ex. TBODY->TR->TD.
Why does the second TBODY node only appear when the table is present
when the page is loaded, and why does its absence influence sort and
And how do I fix it?