Links

Lists

Latest Updates

Ruby On Rails List
Python list
Advanced Java
The JavaScript List
Apache Users
Full Disclosure
Linux Security

Search the archives!


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Javascript] Javascript Tree menu


  • From: bdotjones at gmail.com (Brian Jones)
  • Subject: [Javascript] Javascript Tree menu
  • Date: Fri Oct 20 13:02:31 2006

> My approach to this problem would be different -- instead of messing
> with style and innerHTML attributes, I'd toggle the sub-menus by
> toggling the classNames of the clicked LIs between 'expanded' and
> 'collapsed' or whatever.  Then you can define those classes in your
> stylesheet to include image name (a background image on the LI
> element) and the display property of the child ULs.


Hi Paul,

I changed it to getElementsByTagName("UL") but know when i click
collapse all it hides the whole menu and the expand all still does not
work...How would i changed the javascript to go about doing it the way
that you suggested