CKEditor Integration
  1. CKEditor Integration
  2. CKEDITOR-134

Unclosed {{html}} results in addition of closing tag even when macro isn't actually evaluated

    Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.10
    • Fix Version/s: 1.11
    • Labels:
      None
    • Similar issues:

      Description

      Repro:

      1. Add the following anywhere within a wiki page and save it:

      {{code}}{{html}}{{/code}}
      

      2. Edit the wiki page with CKEditor.
      3. Observe that

      {{/html}}

      gets automatically added to the end of the page content.

      Since the html macro was not actually evaluated as a macro, XWiki shouldn't be trying to close its tag in this way; it should have simply have been treated in the same way a verbatim block is treated.

      An arguably even worse outcome can be obtained by using the following markup:

      {{html wiki=true}}{{{{{html}}}}}{{/html}}
      

      In this case, if you save and edit, you will have some messy transformation of the original markup appearing in CKEditor. CKEditor will then "fail to perform conversion" if you switch to Source view.

      I ran into these problem cases when trying to create howto guides for the use of the html macro.

        Activity

        Hide
        Marius Dumitru Florea added a comment -

        Thanks for your report, but please specify the CKEditor Integration version you're using.

        Show
        Marius Dumitru Florea added a comment - Thanks for your report, but please specify the CKEditor Integration version you're using.
        Hide
        Joel Thornton added a comment -

        Sorry about that! CKEditor Integration version 1.10. Updated Affects Version accordingly.

        Show
        Joel Thornton added a comment - Sorry about that! CKEditor Integration version 1.10. Updated Affects Version accordingly.
        Hide
        Marius Dumitru Florea added a comment -

        Thanks! I'll look into this.

        Show
        Marius Dumitru Florea added a comment - Thanks! I'll look into this.
        Hide
        Marius Dumitru Florea added a comment -

        The issue can be reproduced also with:

        • image reference
          [[image:Sandbox.One{{html}}Two@XWikiLogo.png||alt="{{html}}"]]
          
        • macro parameter
          {{box cssClass="{{html}}"}}inside{{/box}}
          
        Show
        Marius Dumitru Florea added a comment - The issue can be reproduced also with: image reference [[image:Sandbox.One{{html}}Two@XWikiLogo.png||alt="{{html}}"]] macro parameter {{box cssClass="{{html}}"}}inside{{/box}}

          People

          • Assignee:
            Marius Dumitru Florea
            Reporter:
            Joel Thornton
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:
              Date of First Response: