• I am trying to display certain custom fields of all subpages of a parent. I would like to place this within a loop.

    Here is the static code below:

    [Code moderated as per the Forum Rules. Please use the pastebin]

    This is actually a jquery image gallery.

    I found this code that works for a page thumbnail and pulls it from all of the sub pages of a parent but am not sure how to convert it to pull a special field from all sub pages. Any help would be greatly appreciated!!!

    Here is the thumbnail code:

    <?php query_posts(array('post_parent' => 6, 'post_type' => 'page')); while (have_posts()) { the_post(); ?>
                <?php if ( has_post_thumbnail() ) {?>
                    <?php the_post_thumbnail(); ?>
                <?php } else { ?>
                    <!-- Else Don't show anything -->
                <?php } ?>
        <?php } ?>

  • The topic ‘Display custom fields of all sub pages’ is closed to new replies.