Hi there,

Does anyone know of a good script to recursively parse an XML document visiting all nodes. I'm doing this because I'm storing a hierarchical Web site that allows users to create an remove as many pages, sections as they want. I'm using a Flex component to handle building the tree, however I then need to parse the file to create a menu, sub-sections, etc.

An example of the XML might be:

Code:
<sections>
     <section title="Education">
             <section title="Health">
                       <section title="Physical Health">
                              <page title="Muscle Health 101" />
                       </section>
                       <section title="Mental Health">
                              <page title="Wellness" />
                       </section>
             </section>
             <section title="Biology">
                      <page title="Bio 101" />
                      <page title="Bio 202" />
             </section>
     </section>
     
</sections>