Uploaded image for project: 'Confluence'
  1. Confluence
  2. CONFLUENCE-290

Link tags not handled properly when inside a macro parameter

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 9.57.0
    • 9.56.0
    • Syntax - XHTML
    • None
    • Unknown
    • N/A
    • N/A

    Description

      In certain versions on confluence, external link passed as parameters are not handled properly. Instead of being passed as a parameter to the macro event, it is handled as a standalone link, outside the macro call. For example, the following confluence syntax:

       

      <ac:structured-macro ac:name="lozenge" ac:schema-version="1"
          ac:macro-id="40373a62-b942-4525-b8d1-3771615f053a">
          <ac:parameter ac:name="color">blue</ac:parameter>
          <ac:parameter ac:name="arrow">none</ac:parameter>
          <ac:parameter ac:name="icon">https://icon-library.com/images/img_524932.png</ac:parameter>
          <ac:parameter ac:name="link">
              <a href="https://www.bing.com/images/search?q=icon">
                  https://www.bing.com/images/search?q=icon</a>
          </ac:parameter>
          <ac:parameter ac:name="width">auto</ac:parameter>
          <ac:parameter ac:name="title">Some vewy pwetty title</ac:parameter>
          <ac:rich-text-body>
              <p>ALSDLJDLKJ jhkdaskj kjaskjhdaksj huoquwoeiwqu oidaoiduasoiu oiqwkhlklwqejlk
                  kjldaslasjkldasqw op oiqo[ewq][ kfdskl;fsklj kjl klasd </p>
          </ac:rich-text-body>
      </ac:structured-macro>

      Results in the following xwiki syntax:

       

      [[https:~~/~~/www.bing.com/images/search?q=icon>>url:https://www.bing.com/images/search?q=icon||shape="rect"]]
      
      {{lozenge color="blue" arrow="none" icon="https://icon-library.com/images/img_524932.png" width="auto" title="Some vewy pwetty title"}}
      ALSDLJDLKJ jhkdaskj kjaskjhdaksj huoquwoeiwqu oidaoiduasoiu oiqwkhlklwqejlk kjldaslasjkldasqw op oiqo[ewq][ kfdskl;fsklj kjl klasd
      {{/lozenge}} 

      The "link" parameter contains an external url that is stored, for some reason, as a html <a> tag.

      This parameter should also be found in the xwiki macro call.

      Attachments

        Activity

          People

            tcaras Teodor Caras
            tcaras Teodor Caras
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: