|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now! |
|
#1
|
|||
|
|||
|
what is the diff between these and when should I use either?
TIA |
|
#2
|
|||
|
|||
|
The when statement is used in conjunction with the choose statement. The end result is a structure similar to switch statements in languages like C++, javascript, etc.
So, you use an if statement if you simply want to test a single condition for validity. If you need to test a series of conditions similar to an if...else if...else if... structure, you would use the chose/when elements. Reference: when @ w3schools |
|
#3
|
|||
|
|||
|
It's important to note that xslt has no "else" clause, so you have to use choose/when if you want to specify a default condition.
__________________
-james |
|
#4
|
|||
|
|||
|
thank you chaps.
|
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > XML Programming > xsl:if / xsl:when |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|