xsl-list
[Top] [All Lists]

Re: [xsl] can a value of a parameter depends on a other value

2011-11-29 11:20:35
Roelof Wobben wrote:

So if the month is in the variable value and the pagenumber in the variable 
then it would be.



<xsl:with-param name="articlesperpage">

<xsl:choose>

<xsl:when test=" $value eq 2005-02 and $page  eq 1>/xsl:when>

</xsl:choose>

</xsl:with-param>

Well "eq" is an XPath 2.0 operator so I am not sure why you use that now after telling us you use XSLT 1.0.
But you can certainly do
  <xsl:when test="$value = '2005-02' and $page = 1">
for the test. I don't see in your code snippet where you actually set the value of the param as you don't have any code inside of the xsl:when. And as you don't have any xsl:otherwise an xsl:if instead of the xsl:choose/xsl:when might suffice.



--

        Martin Honnen --- MVP Data Platform Development
        http://msmvps.com/blogs/martin_honnen/

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--