Revision: 38466
Initial Code
Initial URL
Initial Description
Initial Title
Initial Tags
Initial Language
at January 3, 2011 18:34 by fidiz
Initial Code
<?php if ( is_page() ) {
if($post->post_parent)
$children = wp_list_pages('sort_column=menu_order&title_li=&child_of='.$post->post_parent.'&echo=0');
else
$children = wp_list_pages('sort_column=menu_order&title_li=&child_of='.$post->ID.'&echo=0');
if ($children) {
?>
<div class="sidebar">
<h2>Sub-pages of Current Page</h2>
<ul>
<?php echo $children; ?>
</ul>
</div>
<?php
} // End If Post
} // End if is page
?>
Initial URL
http://www.martin-gardner.co.uk/how-to-list-wordpress-child-pages-only-on-that-parent-page/
Initial Description
Initial Title
List WordPress Child Pages in Parent Page
Initial Tags
wordpress
Initial Language
PHP