This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes XML and Related Technologies and the fly likes XSLT sorting by param / XPATH Problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "XSLT sorting by param / XPATH Problem" Watch "XSLT sorting by param / XPATH Problem" New topic
Author

XSLT sorting by param / XPATH Problem

Ben Klug
Ranch Hand

Joined: Jan 28, 2002
Posts: 45
Hello,

I have the this xslt-stylesheet:



this works fine. but when I pass the sortfield "request-information/userid" into the parameter sort1 (or "request-information/username") and replace the sorting tag with <xsl:sort select="{$sort1}" order="ascending" /> it is not working. I found some documentation, but that did not work with my situtaution, because my sortfield is not a child of <for:each / >

How can I solve this?

Thanks so much! B.
[ February 04, 2005: Message edited by: Ben Klug ]
Madhav Lakkapragada
Ranch Hand

Joined: Jun 03, 2000
Posts: 5040
Can't really comment much about the style sheet without knowing the input....

- m


Take a Minute, Donate an Hour, Change a Life
http://www.ashanet.org/workanhour/2006/?r=Javaranch_ML&a=81
 
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
 
subject: XSLT sorting by param / XPATH Problem
 
jQuery in Action, 3rd edition