indent = 0; $this->first = true; $this->treeCount = 0; $this->imgCount = 0; $this->output = ""; } // addItem, adds a child to this menu // Takes a XNode object reference as argument function &addItem(&$node) { $this->items[] = &$node; return $this->items[count($this->items) - 1]; } // generateTree, generates the HTML code (UL list) for the dynamic tree-view function generateTree($root = false) { if(!$root) $root = $this; if($this->first){ $this->output .= $this->codeIndent()."