<?php
$mypages = get_pages('child_of='.$post->ID.'&sort_column=post_date&sort_order=desc');
$count = 0;
foreach($mypages as $page)
{
$content = $page->post_content;
if(!$content)
continue;
$content = apply_filters('the_content', $content);
?>
<h2><a href="<?php echo get_page_link($page->ID) ?>"><?php echo $page->post_title ?></a></h2>
<div class="entry"><?php echo $content ?></div>
<?php
}
?>
display child pages on parent page php code with codex
(1 post) (1 voice)-
Posted 13 years ago #
Reply
You must log in to post.