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

Allow anchors in Links to Attachments

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Unresolved
    • Minor
    • None
    • 10.6.1
    • Old Core
    • None
    • Unknown

    Description

      Currently if trying to set an anchor in a link to an attachment, like:

      [[PDF (page 2)>>attach:some_pdf.pdf||anchor="page2"]]
      

      this renders as

      <a anchor="page2" href="/xwiki/bin/download/path/to/page/some_pdf.pdf">PDF (page 2)</a>
      

      Aside of the fact that an "anchor" attribute does not exist in HTML (as far as I know) it might be nicer to render this as href="/xwiki/bin/download/path/to/page/some_pdf.pdf#page2" because at least some browsers understand the #pageX to open the PDF attachment on page X.

      Admittedly browser support is spotty as this is no W3C standard, and for other types of attachments it is useless, but in the current implementation it is useless completely instead of only 95% of the time.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              camil7 Clemens Robbenhaar
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated: