|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
conditional statements
Hi
I'm new to xml I just have a question about if and select statments. For example if I have the following "if test" statement that states price is greater than 10 <xsl:if test="price>'10'"> but how would I make it so it says greater than 10 or less than 5. I know other programming languages you would write the above statement as if (price >10 || price <5) also if you have the following "select" statement that selects artist <xsl:sort select="artist"/> but how would I rewrite the statement to select artist and painters? Please help getchoo |
|
#2
|
|||
|
|||
|
it's someting like this..( your path will probably be different):
<xsl:if test="/price > 10 or /price < 5"> <xsl:value-of select="//element_with_path"/> </xsl:if> selecting artist and painters you would use: and again you will have to provide the correct path. it's alittle tough without the xml document structure, but just make the adjustment with your path and elements ---------------------------------------------- Operators: ---------------------------------------------- and or ==================================== hope that helped... justin.dago Last edited by justin_dago : July 19th, 2002 at 04:32 PM. |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > XML Programming > conditional statements |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|