Support » Plugin: Seriously Simple Podcasting » The podcast episodes tags lead to a 404 page

  • Resolved timefortales

    (@timefortales)


    Hi !

    First of all, thank you for this awesome plugin !

    I use tags for my podcast episodes, but when I click on one of them, it always lead me to a “Sorry, no posts matched your criteria.” page. When I create a “normal” blog post, and that I click on a tag, they work, the podcast episodes tags are the only one that do not work.

    Do you know what I can do to solve that ? I’d like the tags to show me the blog posts AND the podcast posts !

    (I don’t know if it’s helpful, but I’m using the Podcaster theme).

    Thanks !

    • This topic was modified 2 years, 3 months ago by  timefortales.
Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author simondowdles

    (@simondowdles)

    Hi timefortales,

    Thanks for bringing this up. Although the tag is correctly linked to the post type, WordPress will not query anything but the “post” type when searching for tagged items.

    To rectify this, you can add this line of code to your theme functions.php file:

    
    function ssp_tagify( $query ) {
        if ( $query->is_tag() && $query->is_main_query() ) {
            // Add additional post types to this array if need be
            $query->set( 'post_type', array( 'post', 'podcast' ) );
        }
    }
    
    add_action( 'pre_get_posts', 'ssp_tagify' );
    

    I will try get this into the core within the next one or two releases.

    Regards,
    Simon

    • This reply was modified 2 years, 3 months ago by  simondowdles.

    Hi,

    I just added what you posted, and I can confirm you that it works.

    Thanks a lot !!!

    Plugin Author simondowdles

    (@simondowdles)

    Fantastic, happy podcasting 🙂

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘The podcast episodes tags lead to a 404 page’ is closed to new replies.