This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: How to define a xsl:sort's order attribute using a variable


> I want to sort a list of <person> elements, and define the
> "select" and
> "order" attributes of the xsl:sort element using variables,
> rather than
> hardcoded values.

Take a look in the FAQ.

order is an attribute value template.

select is an expression that gives the sort key, not an expression that
gives an expression that gives the sort key. For simple cases use
select="*[name()=$var]", in more complex cases use saxon:evaluate() or
xalan:evaluate().

Mike Kay
Software AG


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]