get_parent_page ??
-
Sorry, but I can’t seem to find this answer. Is there any way to return the name of the current page’s parent?
I use the following code to control the ‘active’ tabs in my navigation:
if (is_page(‘products’)) echo ‘class=”active”‘
I also have:
products/cds
products/dvdsHow can I get WP to return ‘products’ when I am on products/cds for example?
Thank!
Viewing 15 replies - 1 through 15 (of 15 total)
Viewing 15 replies - 1 through 15 (of 15 total)
- The topic ‘get_parent_page ??’ is closed to new replies.