Wrox Home  
Search P2P Archive for: Go

  Return to Index  

javascript_howto thread: Populate Treeview from XML Page


Message #1 by helga@k... on Mon, 8 Apr 2002 06:59:22
To All

I urgently need your assistance.  How do I populate a "Treeview" type of 
effect on a HTML page obtaining the data from a XML page.  The XML page is 
something like this:
<LocalFiles>
  <Category>Animals
    <SubCategory>Dogs
      <FileName>xxxxxx.xxx</FileName>
      <FileLocation>x:\xxxx\xxx</FileLocation>
      <FileName>xxxxxx.xxx</FileName>
      <FileLocation>x:\xxxx\xxx</FileLocation>
    </SubCategory>
    <SubCategory>Cats
      <FileName>xxxxxx.xxx</FileName>
      <FileLocation>x:\xxxx\xxx</FileLocation>
    </SubCategory>
  </Category>
  <Category>Vehicles
    <SubCategory>Ford
      <FileName>xxxxxx.xxx</FileName>
      <FileLocation>x:\xxxx\xxx</FileLocation>
      <FileName>xxxxxx.xxx</FileName>
      <FileLocation>x:\xxxx\xxx</FileLocation>
    </SubCategory>
    <SubCategory>Audi
      <FileName>xxxxxx.xxx</FileName>
      <FileLocation>x:\xxxx\xxx</FileLocation>
    </SubCategory>
  </Category>
</LocalFiles>

The when the user clicks on the node "Animals" the sub categories must 
appear (Dogs & Cats) and when selecting the sub category (i.e. Dogs) the 
files listed under this sub category must appear.


Your help will highly be appreciated

Helga

  Return to Index