Related posts not relating so well

  • Posted in : TheBlogger
  • Thais
    Participant

    Hello,
    I’ve been reading all the help you’ve provided related to “Related Posts”, but I couldn’t solve my problem yet :(

    The related posts section is showing only the same 5 or 6 latest posts, and it isn’t very useful. I’ve been trying a feel plugins (included YARPP), and they substitute your beautiful layout for this section or don’t have any effect.

    I’d like to have my blog’s related posts showing up post based on tags, and I found a little code with the variables that I’d like to be considered in this section. Could you help me to make the piece of code bellow to work with the theme? Thanks!

    <?php $orig_post = $post;
    global $post;
    $tags = wp_get_post_tags($post->ID);
    if ($tags) {
    $tag_ids = array();
    foreach($tags as $individual_tag) $tag_ids[] = $individual_tag->term_id;
    $args=array(
    ‘tag__in’ => $tag_ids,
    ‘post__not_in’ => array($post->ID),
    ‘posts_per_page’=>5, // Number of related posts that will be shown.
    ‘caller_get_posts’=>1
    );
    $my_query = new wp_query( $args );
    if( $my_query->have_posts() ) {
    echo ‘<div id=”relatedposts”><h3>Related Posts</h3>

    </div>’;
    }
    }
    $post = $orig_post;
    wp_reset_query(); ?>

    Mehmet S.
    Keymaster

    Hi, we will improve the “Related Posts” functionality with the next update. Thanks for the feedback.

    Thais
    Participant

    Thanks for your answer, Mehmet. There’s any prevision of when the next update will be released?

    serkan
    Moderator

    Hi, We are working very hard right now and it may take a few weeks for the new update to arrive. You will be notified of the update released.
    Thanks for your patience.

    Mehmet S.
    Keymaster

    Hi, we have just released a new update with the fix, you can download and update your theme now.

    https://themeforest.net/user/pixelwars/portfolio

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in and have valid license to reply to this topic.

License required for the following item
Login and Registration Log in · Register