I'm using the following code I got from the Wordpress codex:
<?php // Displaying Child pages of the current page in post format
$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;
if($count >= 20)
break;
$count++;
$content = apply_filters('the_content', $content);
?>
<div class="content-block">
<h2><a href="<?php echo get_page_link($page->ID) ?>"><?php echo $page->post_title ?></a></h2>
<a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'twentyten' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_post_thumbnail(); ?></a>
<?php echo $content ?>
</div>
<?php
}
?>
I tried the following code to get the featured image of the page:
<a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'twentyten' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_post_thumbnail(); ?></a>
and this one too:
$thumbnail = apply_filters('the_post_thumbnail', $thumbnail);
But it doesn't get the featured image.
Any suggestions?