ThemeShaper Forums » Thematic


listing children pages with their thumbnails

(2 posts)
  • Started 10 years ago by joperron
  • Latest reply from helgatheviking
  • This topic is resolved
  1. Hello!

    Here's a bit of code I use a lot, just thought I would share with you guys. I usually put it in a new page template and apply to it top level pages who have children but not necessarily their own content.

    Make sure your install supports thumbnails:


    Here it is:

    <ul class="subpages">
    <?php $parent = $post->ID; ?>
    <?php query_posts('posts_per_page=15&order=ASC&orderby=menu_order&post_type=page&post_parent='.$parent);
     while (have_posts()) : the_post();?>
    <li> <?php the_post_thumbnail(); ?><a>"><h3><?php the_title(); ?></h3></a></li>
    <?php endwhile; ?>

    Works for me, but as always with those things... YMMV


    Posted 10 years ago #
  2. neat idea. do you have a demo somewhere? fyi- Thematic already has the add_theme_support so in your child you don't need that anymore. also have you tried using get_posts? supposedly it is safer than query posts, as it shouldn't mess w/ your regular query. i usually use it for any other loops.

    Posted 10 years ago #

RSS feed for this topic

Topic Closed

This topic has been closed to new replies.