Simon Willison’s Weblog


Tree from unordered list

13th June 2002

The amazing tree generator (via webgraphics, who in turn got it from CSS Discuss). This is just the kind of DHTML I really like. Place a simple nested unordered list in your document and this external javascript can use the DOM to convert the list in to a hierarchical outline style tree, with each node expandable to show the child members. It looks great and works in both IE and Mozilla—I haven’t tested it in other browsers but it should degrade gracefully, leaving them with a static nested list.

This is Tree from unordered list by Simon Willison, posted on 13th June 2002.

Next: Mozilla alpha

Previous: Charity and Amazon

Previously hosted at