XSL if-expression question
Here should go questions about transforming XML with XSLT and FOP.
XSL if-expression question
OxygenXML is rejecting the following usage with "Unknown system function: if"
I have XPath level set to 2.0
<xsl:variable name="qd"
select="if(value/qDisplay/text() eq '')
then 'empty'
else 'right'"/>
Is this syntactically correct?
I have XPath level set to 2.0
<xsl:variable name="qd"
select="if(value/qDisplay/text() eq '')
then 'empty'
else 'right'"/>
Is this syntactically correct?
Hi,
Where did you set the XPath level to 2.0?
If you edit a stylesheet then you should specify in xsl:stylesheet version="2.0"
Best Regards,
George
Where did you set the XPath level to 2.0?
If you edit a stylesheet then you should specify in xsl:stylesheet version="2.0"
Code: Select all
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="2.0">
George
Hi,
As George said, you have to change the xsl:stylesheet's version attribute to 2.0 in order for it to validate a version 2.0 XPath "if() then else" expression.
This is also true for running a transformation on the stylesheet (you have to run it using the Saxon 8B transformer).
Indeed, if the stylesheet version remains 1.0 you get the error reported above.
Regards,
Radu
As George said, you have to change the xsl:stylesheet's version attribute to 2.0 in order for it to validate a version 2.0 XPath "if() then else" expression.
This is also true for running a transformation on the stylesheet (you have to run it using the Saxon 8B transformer).
Indeed, if the stylesheet version remains 1.0 you get the error reported above.
Regards,
Radu
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