Opened 11 years ago
Closed 10 years ago
#12076 closed bug (patchwelcome)
In IE8 and below, time elements in cloned table elements have incorrect tag structures
Reported by: | Owned by: | Rick Waldron | |
---|---|---|---|
Priority: | high | Milestone: | None |
Component: | manipulation | Version: | 1.7.2 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
In IE8 and below, time
elements in cloned table
elements have incorrect tag structures like <:time>2012-07-12</:time>.
Change History (8)
comment:1 Changed 11 years ago by
Component: | unfiled → manipulation |
---|---|
Owner: | set to Rick Waldron |
Priority: | undecided → high |
Status: | new → assigned |
comment:2 Changed 11 years ago by
Priority: | high → low |
---|---|
Resolution: | → invalid |
Status: | assigned → closed |
comment:4 Changed 11 years ago by
Resolution: | invalid |
---|---|
Status: | closed → reopened |
Forgive me - it's late, I'm tired and I missed that. Re-opening.
comment:5 Changed 11 years ago by
Priority: | low → high |
---|---|
Status: | reopened → assigned |
comment:6 Changed 11 years ago by
When I remove the table from the equation, it works fine, but whenever the unknown element is the child of the element being cloned, the whole system breaks down. I'll look at this further tomorow.
comment:8 Changed 10 years ago by
Resolution: | → patchwelcome |
---|---|
Status: | assigned → closed |
The only reasonable solution to solving this is to copy innerHTML from the source element into the clone element. Since we only want to do this when a non-native element (ie. HTML5 nodes are not native in oldIE) appears as a child of the element being cloned. To do this, we need to look at all of the children of the element being cloned and check if any have a nodeName that matches the known and supported HTML5 nodeNames. If any of those children have children themselves, then we need to traverse downward and run the same check on all of those children (and of course, so on down through all children). When the nest is only one or two branches deep, with a only a handful of children, this will work just fine. The problem comes when there are very deeply nested DOM trees with large children counts. In those cases, this approach becomes unrealistic.
jQuery does not shim HTML5 elements, you MUST include html5shiv
http://code.google.com/p/html5shiv/