wp_list_page – exclude current page
-
Hi
I have searched and tried various plugins and snippets to create a nav in my page.php template that shows the child pages, *siblings* and parent pages… not sure my terminology is right there… but my problem is trying to exclude the current page from the this is what I’ve got so far:
I’m using breadcrumb nav-xt plugin and a wp_list_pages
<li> <?php if (class_exists('bcn_breadcrumb')) { // New breadcrumb object $mybreadcrumb = new bcn_breadcrumb; // Assemble the breadcrumb $mybreadcrumb->assemble(); // Display the breadcrumb $mybreadcrumb->display(); } ?> </li> </div> <?php if($post->post_parent) $children = wp_list_pages("title_li=&child_of=".$post->post_parent."&echo=0"); else $children = wp_list_pages("title_li=&child_of=".$post->ID."&echo=0"); if ($children) { ?> <ul> <?php echo $children; ?> </ul> <?php } ?>I have read http://codex.ww.wp.xz.cn/Template_Tags/wp_list_pages
and found
<?php wp_list_pages('exclude=17,38' ); ?>but cant figure out where to put the exclude and/or how to exclude the *current* page in the wp_list_pages
if that makes any sense, please help me out?
thank you
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
The topic ‘wp_list_page – exclude current page’ is closed to new replies.