Uploaded image for project: 'Confluence Data Center'
  1. Confluence Data Center
  2. CONFSERVER-23328

We display the page name and # character for relative anchor links + make anchor links relative (in the XHTML storage format for Confluence 4.0+).

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: High High
    • 4.0.3
    • None
    • None

      NOTE: This bug report is for Confluence Server. Using Confluence Cloud? See the corresponding bug report.

      That is, [#foo] on a page called "Test Page" renders with an alias / link body of "Test Page#foo". In Confluence 3.5 we only displayed "foo" which is a lot nicer.

      This was raised as regression in some of our documentation pages.


      The second part of this issue is to make anchor links relative again in Confluence 4.0+, which isn't the case in the initial Confluence 4.0 release.

      In other words, if a link leads to a target location on the same page (e.g. an anchor link), then in the XHTML storage format, don't store the page reference in the link itself. This was how Confluence 3.5 effectively used to work (in part because its content was stored in 'less sophisticated' wiki markup). However, since all links were treated as absolute links in the initial release of Confluence 4.0, this was causing all sorts of problems like:

      For an initial discussion on how Confluence 4.0 should handle anchor links 'relatively', see this comment on CPSP-45

        1. screenshot-1.jpg
          115 kB
          Edwin Dawson [Atlassian]

            [CONFSERVER-23328] We display the page name and # character for relative anchor links + make anchor links relative (in the XHTML storage format for Confluence 4.0+).

            Katherine Yabut made changes -
            Workflow Original: JAC Bug Workflow v3 [ 2898609 ] New: CONFSERVER Bug Workflow v4 [ 2993221 ]
            Owen made changes -
            Workflow Original: JAC Bug Workflow v2 [ 2791075 ] New: JAC Bug Workflow v3 [ 2898609 ]
            Status Original: Resolved [ 5 ] New: Closed [ 6 ]
            Owen made changes -
            Workflow Original: JAC Bug Workflow [ 2721169 ] New: JAC Bug Workflow v2 [ 2791075 ]
            Owen made changes -
            Workflow Original: Confluence Workflow - Public Facing - Restricted v5 - TEMP [ 2400231 ] New: JAC Bug Workflow [ 2721169 ]
            Katherine Yabut made changes -
            Workflow Original: Confluence Workflow - Public Facing - Restricted v5 [ 2299565 ] New: Confluence Workflow - Public Facing - Restricted v5 - TEMP [ 2400231 ]
            Katherine Yabut made changes -
            Workflow Original: Confluence Workflow - Public Facing - Restricted v5.1 - TEMP [ 2233984 ] New: Confluence Workflow - Public Facing - Restricted v5 [ 2299565 ]
            Katherine Yabut made changes -
            Workflow Original: Confluence Workflow - Public Facing - Restricted v5 - TEMP [ 2195867 ] New: Confluence Workflow - Public Facing - Restricted v5.1 - TEMP [ 2233984 ]
            Katherine Yabut made changes -
            Workflow Original: Confluence Workflow - Public Facing - Restricted v5 [ 1927066 ] New: Confluence Workflow - Public Facing - Restricted v5 - TEMP [ 2195867 ]
            Katherine Yabut made changes -
            Workflow Original: Confluence Workflow - Public Facing - Restricted v3 [ 1736778 ] New: Confluence Workflow - Public Facing - Restricted v5 [ 1927066 ]
            jonah (Inactive) made changes -
            Description Original: That is, \[#foo\] on a page called "Test Page" renders with an alias / link body of "Test Page#foo". In Confluence 3.5 we only displayed "foo" which is a lot nicer.

            This was raised as regression in some of our documentation pages.

            !Anchorlinks-busted.PNG!

            ----

            The second part of this issue is to make anchor links relative again in Confluence 4.0+, which isn't the case in the initial Confluence 4.0 release.

            In other words, if a link leads to a target location on the same page (e.g. an anchor link), then in the XHTML storage format, don't store the page reference in the link itself. This was how Confluence 3.5 effectively used to work (in part because its content was stored in 'less sophisticated' wiki markup). However, since all links were treated as absolute links in the initial release of Confluence 4.0, this was causing all sorts of problems like:

            * Displaying the page name and # character for relative anchor links
            * https://studio.plugins.atlassian.com/browse/CPSP-45

            (/) For an initial discussion on how Confluence 4.0 should handle anchor links 'relatively', see [this comment on CPSP-45|https://studio.plugins.atlassian.com/browse/CPSP-45?focusedCommentId=49069&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-49069]
            New: {panel:bgColor=#e7f4fa}
              *NOTE:* This bug report is for *Confluence Server*. Using *Confluence Cloud*? [See the corresponding bug report|http://jira.atlassian.com/browse/CONFCLOUD-23328].
              {panel}

            That is, \[#foo\] on a page called "Test Page" renders with an alias / link body of "Test Page#foo". In Confluence 3.5 we only displayed "foo" which is a lot nicer.

            This was raised as regression in some of our documentation pages.

            !Anchorlinks-busted.PNG!

            ----

            The second part of this issue is to make anchor links relative again in Confluence 4.0+, which isn't the case in the initial Confluence 4.0 release.

            In other words, if a link leads to a target location on the same page (e.g. an anchor link), then in the XHTML storage format, don't store the page reference in the link itself. This was how Confluence 3.5 effectively used to work (in part because its content was stored in 'less sophisticated' wiki markup). However, since all links were treated as absolute links in the initial release of Confluence 4.0, this was causing all sorts of problems like:

            * Displaying the page name and # character for relative anchor links
            * https://studio.plugins.atlassian.com/browse/CPSP-45

            (/) For an initial discussion on how Confluence 4.0 should handle anchor links 'relatively', see [this comment on CPSP-45|https://studio.plugins.atlassian.com/browse/CPSP-45?focusedCommentId=49069&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-49069]

              pcurren Paul Curren
              dave@atlassian.com dave (Inactive)
              Affected customers:
              0 This affects my team
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: