Details
-
Bug
-
Resolution: Fixed
-
Major
-
1.8 RC1
-
None
-
xhtml parser, table cells, table header items, list items, embedded documents, block elements
-
Unit
-
Description
Following (failing) test case illustrates the issue for table cells and table header items:
.#----------------------------------------------------- .input|xhtml/1.0 .#----------------------------------------------------- <table><thead><tr><th><p>Head</p></th></tr></thead><tbody><tr><td><p>Cell</p></td></tr></tbody></table> .#----------------------------------------------------- .expect|xhtml/1.0 .#----------------------------------------------------- <table><thead><tr><th><div class="xwiki-document"><p>Head</p></div></th></tr></thead><tbody><tr><td><div class="xwiki-document"><p>Cell</p></div></td></tr></tbody></table>
And for list items:
.#----------------------------------------------------- .input|xhtml/1.0 .#----------------------------------------------------- <ol><li><p>Item1</p></li></ol> .#----------------------------------------------------- .expect|xhtml/1.0 .#----------------------------------------------------- <ol><li><div class="xwiki-document"><p>Item1</p></div></li></ol>
What is more surprising is the actual xhtml output from the xhtml renderer for above test cases. Following are the passing test cases:
.#----------------------------------------------------- .input|xhtml/1.0 .#----------------------------------------------------- <table><thead><tr><th><p>Head</p></th></tr></thead><tbody><tr><td><p>Cell</p></td></tr></tbody></table> .#----------------------------------------------------- .expect|xhtml/1.0 .#----------------------------------------------------- <table><tr><th></th></tr></table><p>Head</p><table><tr><td></td></tr></table><p>Cell</p>
And:
.#----------------------------------------------------- .input|xhtml/1.0 .#----------------------------------------------------- <ol><li><p>Item1</p></li></ol> .#----------------------------------------------------- .expect|xhtml/1.0 .#----------------------------------------------------- <ol><li></li></ol><p>Item1</p>
As you can see, the xhtml output from the xhtml renderer doesn't make any sense.
Attachments
Issue Links
- is duplicated by
-
XWIKI-2804 Html tables with attributes and internal <p> tags are not rendered properly
- Closed
-
XWIKI-2812 Lists with internal <p> tags are not rendered properly.
- Closed
- is related to
-
XRENDERING-5 List items that contain sub-items followed by text are not rendered properly
- Open
- relates to
-
XWIKI-6336 XHTML tables are badly converted to XWiki 2.0 syntax if a table cell contains a paragraph with just a line break
- Closed
-
XWIKI-6178 Format changes when saving or switching mode after importing excel file
- Closed