Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to keep parent page main menu link current while on child page?
#6
Carlos Wrote:
Dominic Wrote:What I would like to do is have the link to the parent page stay "current" while someone is on that page's children.

Edit your template and change:

Code:
<?php get_navigation(return_page_slug()); ?>

to:

Code:
<?php get_navigation(get_parent(0)==''?return_page_slug():get_parent(0)); ?>


Carlos, this worked perfectly! And when I remembered to put it in the UL tags I didn't even have to restyle it! Thank you!!!
Reply


Messages In This Thread
How to keep parent page main menu link current while on child page? - by Dominic - 2012-02-02, 02:11:03



Users browsing this thread: 1 Guest(s)