OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]

Subject: Convert a relative file link to a URL in docbook

I am using docbook as a source for HTML and PDF output. In the docbook source, I have a series of links which are relative (pointing to javadoc files), which is fine for the HTML output because the javadoc files are deployed alongside the original document. For the PDF output, I would like to convert these to absolute links by way of prepending a URL prefix. Is this possible? I have added a 'relative' role to these links and have tried adding a fo customization layer:

<xsl:template match="d:link[@role='relative']">
    <xsl:attribute name="xlink:href">
      <xsl:value-of select="concat('http://prefix/', @xlink:href)"/>
  <xsl:apply-templates select="d:link"/>

This seems to half-work in that it does prepend the prefix to the link href, but then it does not convert the link element into FO.

Any ideas, or other ways this could be done?

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]