tree.js

Converts <ul> into interactive tree.


Functions


OAT.Tree.assign(div, dir, ext, reformat, classNamePrefix)

This converts a list into an interactive tree. Div specifies a container in which your list lives. Dir is a directory containing important images, ext is their extension and reformat is a boolean value, specifying whether do you want to reformat (i.e. collapse all deep levels) the tree. Every level of resulting tree (i.e. every UL and LI) is then assigned a class name in format of classNamePrefix_ul|li_depth. Example:

OAT.Tree.assign("myDiv", "images", "png", true, "myTree");