PDA

View Full Version : Simple tree menu help



scriptNuB
04-03-2008, 03:13 PM
1) Script Title: Simple Tree menu

2) Script URL (on DD):
http://www.dynamicdrive.com/dynamicindex1/navigate1.htm
3) Describe problem:
Currently we are using the tree menu for navigation and when the user clicks on a menu option it opens a new page and the menu is collapsed. Is there a way to keep the menu option expanded for that page?

Example:
Menu1
Menu2
Menu3
Opt1
Opt2
Opt3

If the user clicks Opt3 Under Menu3, it takes them to stuff.asp, on stuff.asp, I want to see,
Menu1
Menu2
Menu3
Opt1
Opt2
Opt3

is there a way to do this?

Nile
04-04-2008, 11:37 AM
Do you want everything the way it was at? Or only the page folder?

scriptNuB
04-04-2008, 12:26 PM
what do you mean?

When the site first loads the menu is there as

Menu1
Menu2
Menu3

If the user selects Menu3 it then expands as
Menu3
Opt1
Opt2
Opt3

Then if the user selects Opt3 (for example) it takes them to a whole new page and this page has the menu as well. Instead of showing the menu as
Menu1
Menu2
Menu3
on the new page, I want to show the menu expanded with the menu option expanded so it would look like this on the Menu3 --> Opt3 page

Menu1
Menu2
Menu3
Opt1
Opt2
Opt3

molendijk
04-04-2008, 05:43 PM
You could try to give the appropriate ul an id (like: <ul id="open'>), then have on pageload:
onload="document.getElementById('open').style.display='inline'"
Since the question which items should be visible on pageload depends on specific pages, you must provide more than one ul with an id.
Just an idea. I don't really know the menu.
-------
Arie Molendijk.

scriptNuB
04-04-2008, 06:07 PM
yeah, i've tried that and no joy. I even tried doing

onload="expandContent("1")"

and no joy