merged2html5 -- Modifying xref elems
Posted: Fri Sep 07, 2018 3:48 pm
Ok, here's an edge case. To build our release notes we also conref to a list of new features in the product doc. That list of features has xrefs that link to pages in the HTML. The Rel Notes are PDF so those links can't work.
To fix this I make the xref like so:
Then I use the following template in the XSLT
It works like a charm, except for one thing. The statement gets the content within the xref tags (good), AND it gets the short description of the target topic (bad). Further, it seems to just come across concatenated to the tag content, so I don't see a way to parse it out.
Another odd thing is that some of the attributes come across empty or changed. The href attribute changes, and otherprops comes across empty, for example.
Anyway, is there some way I can get rid of the short description that comes with my tag content? How do you know where to break it off?
To fix this I make the xref like so:
Code: Select all
<xref outputclass="PDF_External" deliveryTarget="User Guide"href="foo.xml#myId">Configuring a Group for SSO Authentication</xref>
Then I use the following template in the XSLT
Code: Select all
<xsl:template match="xref[@outputclass = 'PDF_External']">
<xsl:text>"</xsl:text><xsl:value-of select="."/>
<xsl:text>" in the </xsl:text>
<xsl:element name="i">
<xsl:value-of select="@deliveryTarget"/>
</xsl:element>
</xsl:template>
Code: Select all
<xsl:value-of select="."/>
Another odd thing is that some of the attributes come across empty or changed. The href attribute changes, and otherprops comes across empty, for example.
Anyway, is there some way I can get rid of the short description that comes with my tag content? How do you know where to break it off?