WordPress.org

Forums

Simple Fields
Display Custom Post Type by Simple Field? (1 post)

  1. jamesguy9
    Member
    Posted 3 years ago #

    Hello all,

    I'm looking to try to filter a Custom Post Type by it's simple field values. For example, display a list of all "Products" which the radio button checked "Oranges.

    This is how I would normally query a custom post type:

    $args = array( 'post_type' => 'products', 'posts_per_page' => 100, 'orderby' => 'title', 'order' => 'ASC' );
    $loop = new WP_Query( $args );
    while ( $loop->have_posts() ) : $loop->the_post();
    echo '<a href="';
    the_permalink();
    echo '" title="';
    the_title();
    echo '">';
    the_title();
    echo '</a>';
    endwhile;

    Any help you could provide is greatly appreciated.

    http://wordpress.org/extend/plugins/simple-fields/

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Simple Fields
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic