DITA processing instruction provided by Astoria to include in webhelp output
Here should go questions about transforming XML with XSLT and FOP.
-
- Posts: 55
- Joined: Tue Mar 13, 2018 6:07 pm
DITA processing instruction provided by Astoria to include in webhelp output
Post by steinbacherGE »
Hi There,
I need to modify the oxygen webhelp DITA-OT plugin to include information that is provided by Astoria within a processing instruction.
Example:
<task>
<?ASTDOCREVINFO __docVernName="1.6" __docVerDesc="Description goes here" __docVerUser="Leroy Steinbacher" __docVerDate="June 19, 2019 12:51:00 PM"?>
So far I've modified ..\plugins\com.oxygenxml.webhelp\xsl\dita\a_pluginOverrides.xml to check for the PI.
xsl:template match="processing-instruction('ASTDOCREFINFO')"
That's as far as I've gotten so far. Any suggestions?
Thanks,
Leroy Steinbacher
I need to modify the oxygen webhelp DITA-OT plugin to include information that is provided by Astoria within a processing instruction.
Example:
<task>
<?ASTDOCREVINFO __docVernName="1.6" __docVerDesc="Description goes here" __docVerUser="Leroy Steinbacher" __docVerDate="June 19, 2019 12:51:00 PM"?>
So far I've modified ..\plugins\com.oxygenxml.webhelp\xsl\dita\a_pluginOverrides.xml to check for the PI.
xsl:template match="processing-instruction('ASTDOCREFINFO')"
That's as far as I've gotten so far. Any suggestions?
Thanks,
Leroy Steinbacher
-
- Posts: 55
- Joined: Tue Mar 13, 2018 6:07 pm
Re: DITA processing instruction provided by Astoria to include in webhelp output
Post by steinbacherGE »
So far I've figure this out. I was able to get the 2 attribute values I needed. I then attached those values to variables and tested them in the output.
<xsl:variable name="astVersion"/>
<xsl:variable name="astDate"/>
<xsl:template match="processing-instruction('ASTDOCREVINFO')">
Version: <xsl:value-of select="substring-before(substring-after(., '__docVerName="'), '"')"/>
Date: <xsl:value-of select="substring-before(substring-after(., '__docVerDate="'), '"')"/>
<xsl:variable name="astVersion" select="substring-before(substring-after(., '__docVerName="'), '"')"/>
<xsl:variable name="astDate" select="substring-before(substring-after(., '__docVerDate="'), '"')"/>
Variable Version: <xsl:value-of select="$astVersion"/>
Variable Date: <xsl:value-of select="$astDate"/>
</xsl:template>
The issue I'm facing now is I need the values of these variables in a different template later in the xsl file.
Any suggestions?
Can I define global variables and get values from the PI attributes outside of a template?
Thanks,
Leroy
<xsl:variable name="astVersion"/>
<xsl:variable name="astDate"/>
<xsl:template match="processing-instruction('ASTDOCREVINFO')">
Version: <xsl:value-of select="substring-before(substring-after(., '__docVerName="'), '"')"/>
Date: <xsl:value-of select="substring-before(substring-after(., '__docVerDate="'), '"')"/>
<xsl:variable name="astVersion" select="substring-before(substring-after(., '__docVerName="'), '"')"/>
<xsl:variable name="astDate" select="substring-before(substring-after(., '__docVerDate="'), '"')"/>
Variable Version: <xsl:value-of select="$astVersion"/>
Variable Date: <xsl:value-of select="$astDate"/>
</xsl:template>
The issue I'm facing now is I need the values of these variables in a different template later in the xsl file.
Any suggestions?
Can I define global variables and get values from the PI attributes outside of a template?
Thanks,
Leroy
-
- Posts: 9434
- Joined: Fri Jul 09, 2004 5:18 pm
Re: DITA processing instruction provided by Astoria to include in webhelp output
Hi Leroy,
I answered you here:
https://stackoverflow.com/questions/566 ... 0#56679010
Ideally you should try not to post the same question in multiple places. Both the DITA users list and stack overflow are good places where to ask DITA XSLT related questions. The DITA Users List is more oriented towards DITA processing, for example on stack overflow you may get answers from people who do not know what DITA is but they know XSLT.
Regards,
Radu
I answered you here:
https://stackoverflow.com/questions/566 ... 0#56679010
Ideally you should try not to post the same question in multiple places. Both the DITA users list and stack overflow are good places where to ask DITA XSLT related questions. The DITA Users List is more oriented towards DITA processing, for example on stack overflow you may get answers from people who do not know what DITA is but they know XSLT.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service