Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1266936
    Karl K
    Participant

    I was wondering if there was a way to automatically add related posts to the bottom of a post and have those posts match the post category?

    I am currently using the code below with essential grid to show recent posts, which is working great.

    function single_post_r_shortcode($contents) {
    	if(is_singular()) $contents .= do_shortcode('<h3>More From Guys Drinking Beer</h3>[ess_grid alias="recent"]'); 
    	return $contents;
    }

    Is there anything I could add to recreate this code to have the most recent “Beer News” posts at the bottom of a post in the “Beer News” category?

    And, for what it’s worth, I’m not married to using the essential grid shortcode if that complicates things.

    Thanks in advance,

    Karl

    #1267038
    Rupok
    Member

    Hi Karl,

    You need to use a plugin to achieve this. Let’s try finding an appropriate one that suits you best as it’s not a theme feature to add related posts.

    Thanks!

    #1277920
    Karl K
    Participant

    Thought it would be worth a try to ask. Thanks for the response.

    #1278088
    Friech
    Moderator

    Should you require any further assistance with X|THEME and Cornerstone, please feel free to get in touch with us.

    Thanks.

  • <script> jQuery(function($){ $("#no-reply-1266936 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>