query post for childpages
-
I would like to run a query and get the excerpt of more than one childpage but only showing the recent page of all those childpages.
Example: Page- Childpage ID=111 -Grandchild1
-Grandchild2Childpage2 ID=134 -Grandchild3
-Grandchild4
-Grandchild5I would like to query childpage 1 and 2 but only showing the latest page of the 5 grandchilds.
At the moment im using
<?php query_posts('post_type=page&child_of=111&showposts=1&monthnum=$current_month'); ?> <?php while (have_posts()) : the_post(); ?> <div class="green1"> <h1><?php the_title(); ?></h1> <?php the_excerpt(); ?> <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">weiterlesen...</a> </div> <?php endwhile; ?>
which works fine fpr 1 Childpage but i dont know how to make a query for more than one child of.
Would be cool if i could use a query to display the newest page out of 111 and 134
Greetings Baal Orun
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘query post for childpages’ is closed to new replies.