Viewing 1 replies (of 1 total)
  • Thread Starter grapesodabanked

    (@grapesodabanked)

    Alright! This probably depends on how you registered your taxonomies and everything, but I got it to work like this with what I’m working on:

    in the $default_params array, add this:
    ‘post_type’ => ”,
    ‘tax_query’ => array(
    array(
    ‘taxonomy’ => ”,
    ‘field’ => ‘slug’,
    ‘terms’ => ”
    )
    )

    in the $get_post_args array, add this:
    ‘post_type’ => $params[‘post_type’],
    ‘tax_query’ => array(
    array(
    ‘taxonomy’ => $params[‘taxonomy’],
    ‘field’ => ‘slug’,
    ‘terms’ => $params[‘term’],
    )
    )

    my shortcodes now work like this:
    [message-flow taxonomy=”insert taxonomy slug” term=”insert taxonomy term slug” post_type=”insert post type slug”]

    Can someone confirm that this is a good approach or expand on this?

Viewing 1 replies (of 1 total)
  • The topic ‘Custom Taxonomy support?’ is closed to new replies.