|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Generating multi-level flexible recursive nested lists
Hello, I was wondering if somebody can help me to generate Multilevel OL and LI. Here is the input and output expected. If we add some more levels like level4 or level5, xslt should be able generate output without any change in it. I have been trying this since many days. I would highly appreciate your help. Thanks in advance. INPUT ---- <doc> <p style="level1"> ALevel1 </p> <p style="level1"> BLevel1 </p> <p style="level2"> aLevel2 </p> <p style="level2"> bLevel2 </p> <p style="level1"> CLevel1 </p> <p style="level1"> DLevel1 </p> <p style="level2"> aLevel2 </p> <p style="level2"> bLevel2 </p> <p style="level3"> iLevel3 </p> <p style="level3"> iiLevel3 </p> <p style="level2"> cLevel2 </p> <p style="level1"> ELevel1 </p> </doc> OUTPUT EXPECTED --------------- <doc> <ol> <li> ALevel1 </li> <li> BLevel1 </li> <ol> <li> aLevel2 </li> <li> bLevel2 </li> </ol> <li> CLevel1 </li> <li> DLevel1 </li> <ol> <li> aLevel2 </li> <li> bLevel2 </li> <ol> <li> iLevel3 </li> <li> iiLevel3 </li> </ol> <li> cLevel2 </li> </ol> <li> ELevel1 </li> </ol> </doc> __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Cast Your Vote
We need your help – Vote for DataDirect XML Products!
Winners and finalists announced at SOA World Conference in November. Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|







