[Plugin: The Subtitle] Pulling in child pages, display their sub title?
-
Hi there, I’m pulling in a list of pages, listing them using the following code:
<?php $child_pages = $wpdb->get_results("SELECT * FROM $wpdb->posts WHERE post_parent = 29 AND post_type = 'page' ORDER BY menu_order", 'OBJECT'); ?> <ul class="team-list"><?php if ( $child_pages ) : foreach ( $child_pages as $pageChild ) : setup_postdata( $pageChild ); ?> <li class="team-list"> <div class="child-name"> <a href="<?php echo get_permalink($pageChild->ID); ?>" rel="bookmark" title="<?php echo $pageChild->post_title; ?>"><?php echo $pageChild->post_title; ?></a> </div></li> <?php endforeach; endif; ?></ul>
I’m trying to pull in the sub title, but I can’t seem to get it to work.
Any help would be much appreciated.
Thanks
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘[Plugin: The Subtitle] Pulling in child pages, display their sub title?’ is closed to new replies.