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

XWiki Syntax Guide should not propose to use rel="_blank" since it's invalid in HTML5

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 7.4
    • Fix Version/s: 7.4.1, 8.0-milestone-1
    • Component/s: Help
    • Labels:
      None
    • Difficulty:
      Unknown
    • Documentation:
      N/A
    • Documentation in Release Notes:
      N/A
    • Similar issues:

      Description

      In XWiki Syntax Guide:

      It is suggested to use rel="_blank" to create a link that is open in a new window.

      It made sense when Colibri was the default skin, because target="_blank" was invalid in XHTML 1.0. So we have created this workaround: use rel="_blank" instead and open the link in a new window thanks to a javascript code.

      But in HTML5, it's the exact opposite! target="_blank" is valid and rel="_blank" is not!

      Since I think a lot of users used the "rel" attribute as suggested, I first proposed to add a "hack" in XWIKI-RENDERING (XRENDERING-424) to replace rel="_blank" by target="_blank" when HTML5 is used. But it is not clean, and very specific to XE. So it will probably be reverted.

      In last resort, all we can do is to modify XWikiSyntaxGuide to not suggest to use rel="_blank" but target="_blank".

      It means that the generated code won't be valid with old skins using XHTML 1.0, and also that existing links (with rel="_blank" as suggested) won't be valid with Flamingo.

      Not being strictly valid is not a big issue since it won't make the wiki crash or the browser.

      It also means that we do not fully support other syntax than HTML5.

      Fixing this issue would enable us to fix xwiki-enterprise-test-webstandards.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                gdelhumeau Guillaume Delhumeau
                Reporter:
                gdelhumeau Guillaume Delhumeau
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: