473,408 Members | 1,743 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

XSL if-expression

OxygenXML is rejecting the following usage with
"Unknown system function: if"

<xsl:variable name="qd"
select="if(value/qDisplay/text() eq '')
then 'empty'
else 'right'"/>

Is this syntactically correct? If not, how should it
read?

Jim Garrison
jh*@athensgroup.com
Jun 16 '06 #1
4 1869

<xsl:if test=(name="qd") >

Jim Garrison wrote:
OxygenXML is rejecting the following usage with
"Unknown system function: if"

<xsl:variable name="qd"
select="if(value/qDisplay/text() eq '')
then 'empty'
else 'right'"/>

Is this syntactically correct? If not, how should it
read?

Jim Garrison
jh*@athensgroup.com

Jun 16 '06 #2
That's an XSLT tag.

XPath 2.0 also defines (according to the documentation at w3c)
an if-expression. Look at http://www.w3.org/TR/xpath20/ and
search for IfExpr. This is the XPath equivalent of the
Java/C/C++ ternary operator ?:. It's been in the spec since
2001, and AFAICT I'm using the correct syntax, but Oxygen
doesn't like it.

John Bailo wrote:

<xsl:if test=(name="qd") >

Jim Garrison wrote:
OxygenXML is rejecting the following usage with
"Unknown system function: if"

<xsl:variable name="qd"
select="if(value/qDisplay/text() eq '')
then 'empty'
else 'right'"/>

Is this syntactically correct? If not, how should it
read?

Jim Garrison
jh*@athensgroup.com

Jun 16 '06 #3
Sorry, my original subject line was misleading.

Jim Garrison wrote:
That's an XSLT tag.

XPath 2.0 also defines (according to the documentation at w3c)
an if-expression. Look at http://www.w3.org/TR/xpath20/ and
search for IfExpr. This is the XPath equivalent of the
Java/C/C++ ternary operator ?:. It's been in the spec since
2001, and AFAICT I'm using the correct syntax, but Oxygen
doesn't like it.

John Bailo wrote:

<xsl:if test=(name="qd") >

Jim Garrison wrote:
OxygenXML is rejecting the following usage with
"Unknown system function: if"

<xsl:variable name="qd"
select="if(value/qDisplay/text() eq '')
then 'empty'
else 'right'"/>

Is this syntactically correct? If not, how should it
read?

Jim Garrison
jh*@athensgroup.com

Jun 16 '06 #4


Jim Garrison wrote:
OxygenXML is rejecting the following usage with
"Unknown system function: if"

<xsl:variable name="qd"
select="if(value/qDisplay/text() eq '')
then 'empty'
else 'right'"/>

Is this syntactically correct? If not, how should it
read?


Are you sure you have Oxygen set to use an XSLT 2.0 processor like Saxon
to process that stylesheet?

--

Martin Honnen
http://JavaScript.FAQTs.com/
Jun 17 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: vishal | last post by:
hi i am using session in php. but if the client has disabled his cookie then will my session work or not????????? thxs for your reply in advance.............
3
by: JD | last post by:
I have the below code that displays a small thumbnail if a user is saluted, if they aren't saluted it checks to see if they might have a profile picture, this all works with the exception that is...
11
by: dmbkiwi | last post by:
I am new to this group, and relatively new to python programming, however, have encountered a problem I just cannot solve through reading the documentation, and searching this group on google. I...
4
by: Ryan Lowe | last post by:
i thought id ask here before wirting a PEP, if people thought it would be a good enhancement to allow if clauses in regular for-statements like so: >>> for x in y if x < 10 : is semantically...
303
by: mike420 | last post by:
In the context of LATEX, some Pythonista asked what the big successes of Lisp were. I think there were at least three *big* successes. a. orbitz.com web site uses Lisp for algorithms, etc. b....
6
by: Bart Nessux | last post by:
Should an if statement have a corresponding else statement? Or, is it OK to have an if statement by itself. For completeness, it seems the two should be together, but from experience I know that a...
3
by: Patrice | last post by:
Hi, I need to do multi-conditional statements like below, but this error is displayed : Expected 'End' /myFilepath, line x else response.write(arrCorpo(sparam,sdiv)) end if I don't...
2
by: Jonathan | last post by:
I am looking for a simple way to check if a database table exists. I keep getting advice to use "Try.. Catch" and other error handling methods, but I obviously don't want to have to display an...
17
by: Keith | last post by:
How can I do the following: If recordset is empty, redirect to page1 but if recordset has something in, redirect to page 2. Thanks
6
by: Oplec | last post by:
Hi, I thought that I understood how C++ allows for the declaration and defining of variables within an if() statement and how the declared variable can be used until the end of the major if()...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.