Title: [Plugin: WP Post Type UI] Custom Post loop?
Last modified: August 19, 2016

---

# [Plugin: WP Post Type UI] Custom Post loop?

 *  [hoss9009](https://wordpress.org/support/users/hoss9009/)
 * (@hoss9009)
 * [15 years, 9 months ago](https://wordpress.org/support/topic/plugin-wp-post-type-ui-custom-post-loop/)
 * Sorry… how do I configure the custom post type loop?
    Like this?
 *     ```
       <?php $loop = new WP_Query( array( 'post_type' => 'custom_post_name', 'posts_per_page' => 10 ) ); ?>
       ```
   
 * [http://wordpress.org/extend/plugins/wp-post-type-ui/](http://wordpress.org/extend/plugins/wp-post-type-ui/)

Viewing 3 replies - 1 through 3 (of 3 total)

 *  [MichaelH](https://wordpress.org/support/users/michaelh/)
 * (@michaelh)
 * [15 years, 9 months ago](https://wordpress.org/support/topic/plugin-wp-post-type-ui-custom-post-loop/#post-1548036)
 *     ```
       <?php
       $custom_post_type = 'book';
       $args=array(
         'post_type' => $custom_post_type,
         'post_status' => 'publish',
         'posts_per_page' => -1,
         'caller_get_posts'=> 1
       );
       $my_query = null;
       $my_query = new WP_Query($args);
       if( $my_query->have_posts() ) {
         echo 'List of Books';
         while ($my_query->have_posts()) : $my_query->the_post(); ?>
           <p><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></p>
           <?php
         endwhile;
       }
       wp_reset_query();  // Restore global post data stomped by the_post().
       ?>
       ```
   
 *  Thread Starter [hoss9009](https://wordpress.org/support/users/hoss9009/)
 * (@hoss9009)
 * [15 years, 9 months ago](https://wordpress.org/support/topic/plugin-wp-post-type-ui-custom-post-loop/#post-1548037)
 * this is for the wp-post-type-ui?
    If so, thank you!
 *  [MichaelH](https://wordpress.org/support/users/michaelh/)
 * (@michaelh)
 * [15 years, 9 months ago](https://wordpress.org/support/topic/plugin-wp-post-type-ui-custom-post-loop/#post-1548057)
 * That can be used for post_types created either with that plugin and if done manually
   with [register_post_type](http://codex.wordpress.org/Function_Reference/register_post_type)
   in your theme’s functions.php template.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘[Plugin: WP Post Type UI] Custom Post loop?’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wp-post-type-ui.svg)
 * [WP Post Type UI](https://wordpress.org/plugins/wp-post-type-ui/)
 * [Support Threads](https://wordpress.org/support/plugin/wp-post-type-ui/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-post-type-ui/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-post-type-ui/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-post-type-ui/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [MichaelH](https://wordpress.org/support/users/michaelh/)
 * Last activity: [15 years, 9 months ago](https://wordpress.org/support/topic/plugin-wp-post-type-ui-custom-post-loop/#post-1548057)
 * Status: not resolved