[wp-hackers] wp_list_pages
Aaron D. Campbell
wp-hackers at ezdispatch.com
Mon Jan 7 22:58:55 GMT 2008
I'm trying to display only top level pages AND pages that are either
children of the current page, or children of the ancestors of the
current page. So, if I have a page structure like this:
A
> R
> > U
> > > X
> > > Y
> > > Z
> > V
> > W
> S
> T
B
> P
C
> Q
D
E
F
On the main page, I'd like to display all the top level pages: A, B, C,
D, E, F
On page 'A' I would like to display:
A
> R
> S
> T
B
C
D
E
F
On page 'R' I would like to display:
A
> R
> > U
> > V
> > W
> S
> T
B
C
D
E
F
On page 'U' I would like to display:
A
> R
> > U
> > > X
> > > Y
> > > Z
> > V
> > W
> S
> T
B
C
D
E
F
Basically, it would be like an expanding tree, but it would not use
javascript, it would simply build the menu based on the current page.
It seems like this would be a common desire. Is there something like
this out there, or some simple way of doing it?
More information about the wp-hackers
mailing list