Excerpts for Pages

Using the “more” tag does not create an excerpt. It simply creates a “Read More” link when displaying the_content() on index pages.

Excerpts are created/displayed as follows:

To display an excerpt, your template file needs to call “the_excerpt()” rather than “the_content()”. Note: you use the equivalent $post->post_excerpt, which should also work just fine.

The “the_excerpt()” template tag then displays the excerpt, which is created as follows:

1) By entering excerpt content into the “Excerpt” field on the Edit Post/Edit Page screen.
2) Automatically, based on number of characters, if no content is added to the “Excerpt” field.

EDIT:

Okay so I totally missed this at first. Only Posts have the “excerpt” field. Pages don’t have the “excerpt” field. So, $post->post_excerpt will never be populated for Pages (I think).

Try running “setup_postdata( $pageChild )” inside your foreach loop, and then replacing “$pageChild->post_excerpt” with “get_the_excerpt()”:

foreach ( $pageChildren as $pageChild ) {
    setup_postdata( $pageChild );
    echo '<p>And the title is: '. $pageChild->post_title.'</p>';
        print_r($pageChild);
            echo '<p><a href="' . get_permalink($pageChild->ID) . '">' . get_the_excerpt() .'</a> </p> ';
        echo '<hr />';
}

Does that work?