xsl sorting..urgent!!

I have to modify my xsl for Quadruple output nodes. ie when I get four
content blocks in my xml @value = systemRequirements.
In my xml …i have contentblocks as below

XML------>
-

System requirements
-


Windows1
+

-


Windows2
+
+

-


Macintosh3
+

-


Macintosh4
+




current output start==

windows 1

content of win1 block
--------------------- <–sep.ssi
windows 2

content of win2
--------------------
mac 3

content of mac3
--------------------
mac 4

content of mac 4
--------------------

current o/p end==
I have to sort this according to (standard, premium) edition types
desired output start ==

Standard



Windows1

contents of windows block

mac3

contents of mac3 block

---------------------------- <— seperator.ssi

Premium



windows2

contents of win2 block

mac4

content of mac4 block

-----------------------------------
desired o/p end ==

xml and xsl are as below

http://www.geocities.com/nayanhere/productinfo_gray_CS.xml
http://www.geocities.com/nayanhere/CS2_systemreqs_xsl.txt
Thanks a lot for ur help…
nayana

I don’t know if this will help or not. The attached example shows a two-stage transform using two stylesheets. The first sheet (rank.xsl) examines some xml documents, performs a word count on each document for a selected word (“this”), and inserts a new Element (AUTO-RANK) containing the count value. The second styleseheet (Sort.xsl) then sorts the documents with xsl:sort on the value of the AUTO-RANK Element.
I know this is some way off what you need, but you should be able to adapt it to your needs.
In case it helps, there is also a useful XSL guide >here<.
HTH
Example.zip (1.61 KB)