Skip to main content

Bug Tracker

Side navigation

#442 closed bug (duplicate)

Opened November 27, 2006 03:20PM UTC

Closed November 28, 2006 05:38PM UTC

Last modified June 20, 2007 06:41AM UTC

When appending a tbody to a table, the automatic tbody creation should not occur

Reported by: norbertuco@gmail.com Owned by:
Priority: major Milestone: 1.1a
Component: core Version:
Keywords: table, tbody, append Cc:
Blocked by: Blocking:
Description

I have a table with a thead that does not change and a tbody whose content varies. Each time I refresh the contents of the table, I append the new tr's and td's into a tbody element and append the new tbody element to the table. Unfortunately, when I append the tbody to the table, I get the following:

<table>

<thead>...Constant Content...</thead>

<tbody>

<tbody>...Refreshed Content...</tbody>

</tbody>

</table>

I have changed the following line in the domManip function in order to stop the extra tbody from being appended:

From:


if ( table && this.nodeName.toUpperCase() == "TABLE" && a[0].nodeName.toUpperCase() != "THEAD" ) {


To:


if ( table && this.nodeName.toUpperCase() == "TABLE" && a[0].nodeName.toUpperCase() != "THEAD" && a[0].nodeName.toUpperCase() != "TBODY" ) {


This way I don't get any extra tbody's in my dom.

Attachments (0)
Change History (2)

Changed November 28, 2006 03:51AM UTC by anonymous comment:1

Changed November 28, 2006 05:38PM UTC by brandon comment:2

resolution: → duplicate
status: newclosed