Support » Plugin: Yet Another Related Posts Plugin (YARPP) » YARRP 4.0.5 displays only random articles

  • Well, the subjects says all…

    I have no idea how and why YARPP 4.0.5 now displays only random articles, but it does… Last time I checked the functionality was at the beginning of February. Back then displaying real related, non-random articles worked.

    Oh, and what please is that image tag used for?

    <img src=””></img>

Viewing 9 replies - 1 through 9 (of 9 total)
  • I took some random samples and checked the yarpp_related_cache table. The references in there between reference_ID and ID is ok, also the score seems to be fine.

    Now the question is: Why doesn’t that get displayed?

    I am using <?php related_posts(); ?> in my sidebar

    Thanks for checking the yarpp_related_cache table. You said that the values there look good, but can you verify that the results you’re getting (which you describe as random) are not what are in the cache? Similarly, if you refresh a page, do the “random” results change?

    If it’s just that some are not as relevant as you would like, you should increase the “match threshold” to make YARPP more strict. Go to YARPP settings, go to the screen options tab to show the “relatedness” options, then increase the match threshold and save.

    Finally, the img that you see in your source is there because you opted in to the optional data collection of YARPP settings and usage. This is explained in the YARPP settings page, if you go to the help tab and click on “optional data collection.” You can of course turn this off at any time, but I appreciate your participation.

    Hello Mitcho

    Yes, that is definitely the case. The values in the cache table do not get displayed. Anytime I refresh the website only random posts get displayed, no matter what post, category or tag gets displayed.

    I already flushed the cache table. Without success.

    My current match threshold option value is 3. In the cache table some entries have 5. Setting the option value from 3 to 2, or to 5 doesn’t make any difference. Still only random posts get displayed.


    Wait…. I just discovered that when I activate the option “automatic display related posts at the bottom of the article”, then related articles appear, but only at the bottom of the article.

    The related_posts() function used in my sidebar still only displays random posts, no matter what options are set. Displaying related posts there, in the sidebar, worked before. Strange…

    Thanks for your investigating work! My guess is that this is a weird interaction with other things in your theme or in your sidebar (maybe other plugin’s widgets?) such that when related_posts() is called there, it’s getting incorrect information about what the current post is. Maybe you can try moving your code around within the sidebar? Is there any reason you’re manually coding this in instead of using the YARPP Related Posts widget?

    Hi Mitcho

    I did a little trial and error and it’s a pretty weird interaction in my sidebar.php – the sidebar’s task is to display a list of the website pages, then the related posts, then categories and tags etc…

    When I put related posts before calling wp_list_pages() then it works, but using related posts after wp_list_pages() then only random articles get displayed… Weird… Even more weird when knowing about the fact that it worked a couple of weeks ago. Maybe that’s a WP 3.5.1 issue? That’s the only major update I made.

    @xflow Are you calling the wp_list_pages() yourself in your template code, or is there some widget calling this? Is there some plugin you’re running which might be affecting what’s happening inside the wp_list_pages()?

    Hi Mitcho

    Yes, I am calling the wp_list_pages() myself in my sidebar.php

    Since recently I didn’t install any plugin I doubt that a plugin causes that effect.

    @xflow could you post your full code for your sidebar.php? I’d like to try to reproduce this issue.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘YARRP 4.0.5 displays only random articles’ is closed to new replies.