Click here to Skip to main content
15,892,537 members
Articles / Web Development / CSS

Using XSLT to Generate a Multi-level Tree Menu from XML

Rate me:
Please Sign up or sign in to vote.
4.31/5 (9 votes)
28 Feb 20022 min read 213.6K   1.9K   46  
A simple and generic way to use XSLT to generate a multi-level HTML tree menu from an XML source
<?xml version="1.0"?>
<menu>
 <entry>
  <text>In-House</text>
  <url>InHouse.htm</url>
  <entry>
   <text>Web Development</text>
   <url>WebDev.htm</url>
   <entry>
    <text>Standards</text>
    <url>WebStandards.htm</url>
   </entry>
   <entry>
    <text>FAQ</text>
    <url>WebFAQ.htm</url>
   </entry>
  </entry>
  <entry>
   <text>VB Development</text>
   <url>VBDev.htm</url>
  </entry>
 </entry>
 <entry>
  <text>Microsoft</text>
  <url>http://www.microsoft.com/ms.htm</url>
 </entry>
</menu>

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.


Written By
Web Developer
South Africa South Africa
I live in the Northern Suburbs of Cape Town (South Africa).

Comments and Discussions