Show ONLY subpages of PARENT page IF parent is the CURRENT page.
-
I will try to be specific because I know there are a thousand posts out there re: subpages. I’ve read all the forums and google both to get the outcome I want. SOOOO close each time, but no cigar.
Here’s the scenario:
If I’m on Page A…I want the sidebar to display
Page A Child 1
Page A Child 2
Page A Child 3Additionally, if I’m on any of those Child pages, I want the same list to show.
I do NOT want to display in the sidebar this:
Page A
>Page A Child 1
>Page A Child 2
>Page A Child 3
Page B
Page Cor this…
Page A
>Page A Child 1
>Page A Child 2
>Page A Child 3
Page B
>Page B Child 1
>Page B Child 2
>Page B Child 3
Page Cor this…
Page A Child 1
>Page A Child 1A
>Page A Child 1B
>Page A Child 1C
Page A Child 2
Page A Child 3Also, I would like the actual code for this solution, rather than a plugin because I intend to use it not only in my sidebar, but within the theme itself.
I will keep trying, but in the meantime fingers crossed on a WordPress vet who just knows!
- The topic ‘Show ONLY subpages of PARENT page IF parent is the CURRENT page.’ is closed to new replies.