• Using the WP Types Plugin, I set up a custom post type (slug: portfolio), which has a custom taxonomy (slug: portfolio-category).

    The custom taxonomy has three items (slugs: group1, group2, group3) to organize portfolio posts.

    Now, I am able to display the latest 3 items, using WP_Query:

    $wpex_port_query = new WP_Query(
                array(
                    'post_type' => 'portfolio',
                    'showposts' => '3',
                    'no_found_rows' => true,
                )
            );

    However, what I would like is to filter for a specific item group within the custom taxonomy, e.g. group1, instead of showinng all items from portfolio.

    Unfortunately, I couldn’t get the snippets from the documentation on taxonomy parameters working and I am also not sure if the documentation really applies in this case.

    Would appreciate your advice how to get this working.

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘WP_Query: How to filter slugs within custom taxonomy of custom post type?’ is closed to new replies.