Maven Doxia
  1. Maven Doxia
  2. DOXIA-415

Doxia rejects/rewrites intentional relative http: link in APT

    Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Not A Bug
    • Affects Version/s: 1.1
    • Fix Version/s: None
    • Component/s: Module - Apt
    • Labels:
      None
    • Number of attachments :
      0

      Description

      I wrote:

      {{{http:./jdd/index.html}A Link}}
      

      Because I know that there is going to be such a page by the time my output is deployed. I expected the http: to cause Doxia to 'butt out'. Instead, I get:

      [WARNING] [APT Parser] Modified invalid link: 'http:./jdd/index.html' to '#http:.jddindex.html'
      [WARNING] [APT Parser] Ambiguous link: 'http:./jdd/index.html'. If this is a local link, prepend "./"!

      Notice that I DID prepend ./. Taking out the ./ doesn't help.

        Activity

        Hide
        Lukas Theussl added a comment -

        If you want a relative link you should use

        {{{./jdd/index.html}A Link}}
        

        if you want an absolute link it should start with http://. See http://maven.apache.org/doxia/references/doxia-apt.html#Links.

        Show
        Lukas Theussl added a comment - If you want a relative link you should use {{{./jdd/index.html}A Link}} if you want an absolute link it should start with http:// . See http://maven.apache.org/doxia/references/doxia-apt.html#Links .
        Hide
        Benson Margulies added a comment -

        I think you are making a mistake here. Once someone types in 'http:', you should not look inside at all. However, since you've given me a way out, I won't reopen.

        The doc on relative links could also be a bit clearer that they work even when the content is not coming through doxia.

        Show
        Benson Margulies added a comment - I think you are making a mistake here. Once someone types in 'http:', you should not look inside at all. However, since you've given me a way out, I won't reopen. The doc on relative links could also be a bit clearer that they work even when the content is not coming through doxia.
        Hide
        Lukas Theussl added a comment - - edited

        Doxia does not look any further if you start with http:/. Note the slash.

        I'm not sure what you mean with 'content is not coming through doxia'. Doxia only does the translation between single document formats, so

        {{{./jdd/index.html}A Link}}

        in apt becomes

        <a href="./jdd/index.html">A Link</a>

        in html, and

        {{{index.html}A Link}}

        in apt becomes

        <a href="#index.html">A Link</a>

        in html. Doxia does not care whether the links actually exist. So whether the links actually 'work' depends on whether the target documents are located correctly relative to each other on the target site. This has to be done by the site plugin or whatever tool you use to generate your site.

        Show
        Lukas Theussl added a comment - - edited Doxia does not look any further if you start with http:/. Note the slash. I'm not sure what you mean with ' content is not coming through doxia '. Doxia only does the translation between single document formats, so {{{./jdd/index.html}A Link}} in apt becomes <a href="./jdd/index.html">A Link</a> in html, and {{{index.html}A Link}} in apt becomes <a href="#index.html">A Link</a> in html. Doxia does not care whether the links actually exist. So whether the links actually 'work' depends on whether the target documents are located correctly relative to each other on the target site. This has to be done by the site plugin or whatever tool you use to generate your site.
        Hide
        Benson Margulies added a comment -

        Yes, I now understand that http: {{

        {./ }

        }} does what I want.

        Show
        Benson Margulies added a comment - Yes, I now understand that http: {{ {./ } }} does what I want.

          People

          • Assignee:
            Lukas Theussl
            Reporter:
            Benson Margulies
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: