I thought this code did exactly what I was looking for. However I've now realised that it doesn't sort the page order according to the "WordPress Page Order", it generates them dependent on the date published.
Code:
<?php
$args = array(
'post_type' => 'page',
'numberposts' => 4,
'post_status' => 'publish',
'post_parent' => 7, // any parent
);
$attachments = get_posts($args);
//print_r("attachements:" . $attachements);
if ($attachments) {
foreach ($attachments as $post) { ?>
<div class="feature-products-boximg" style="background:url('<?php $pictures = get_post_meta($post->ID, "image", true); echo $pictures; ?>');">
<a href="<?php the_permalink(); ?>">
<span><?php the_title(); ?></span>
</a>
</div>
<?php
$the_excerpt = get_post_meta( $post->ID, '1lineblurb', $single = true);
if ($the_excerpt != '') { echo($the_excerpt); }// if: filename not blank
}
}
?>
Do any of you know how to modify this so that it generates the pages according to the "WordPress Page Order"?
Thanks
Bookmarks