Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-4122

html macro cleaning drops <legend> tags

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Major
    • None
    • 1.9.2, 2.0 M2
    • Rendering
    • None
    • Unknown

    Description

      HtmlCleaner, the tools currently used for html cleaning in the html macro seems to not knowing the <legend> tag, and it drop it when it is told to drop unknown tags. I have checked the following with the command line of htmlcleaner:

      Therefore:

      <html><head /><body><fieldset>
      <legend>test</legend>
      <div>content</div>
      </fieldset>
      </body></html>
      

      became using java -jar htmlcleaner-2.1.jar src=(above sample in a file) omitunknowntags=true

      <?xml version="1.0" encoding="UTF-8"?>
      <html><head /><body><fieldset>
      test
      <div>content</div>
      </fieldset>
      </body></html>
      

      which is absolutely not what is intended and very difficult to fix with CSS only.

      I had to stop using the cleaner due to this issue, I do not know if there is a way to work around it apart from not removing unknown tags as a whole.

      Attachments

        Issue Links

          Activity

            People

              tmortagne Thomas Mortagne
              softec Denis Gervalle
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: