devxlogo

Create a Collapsible Tree in IE5 Using SrcElement

Create a Collapsible Tree in IE5 Using SrcElement

Browsers Targeted: Internet Explorer 5

Tree structures appear quite often over the ‘Net, and they are becoming especially prominent in the face of the emergence of XML. Fortunately, tree structures are remarkably simple to create, using a combination of list elements and spans. In IE5, you can also take advantage of the srcElement property to simplify making a collapsible tree:

 
    onclick="updateTree()">
  1. Chapter 1
    1. Section 1
      1. Sub-section 1
        1. Paragraph 1
        2. Paragraph 2
        3. Paragraph 3
      2. Sub-section 2
        1. Paragraph 1
        2. Paragraph 2
        3. Paragraph 3
      3. Sub-section 3
        1. Paragraph 1
        2. Paragraph 2
        3. Paragraph 3
    2. Section 2
      1. Sub-section 1
        1. Paragraph 1
        2. Paragraph 2
        3. Paragraph 3
      2. Sub-section 2
        1. Paragraph 1
        2. Paragraph 2
        3. Paragraph 3
      3. Sub-section 3
        1. Paragraph 1
        2. Paragraph 2
        3. Paragraph 3

devx-admin

Share the Post: