Support » Plugin: Yet Another Related Posts Plugin (YARPP) » Can’t use indexing

  • Resolved A2JC4life


    I’ve been using this plugin for years, and loved it, as it was the only one that did as good a job pulling truly-relevant related posts. And then at some point (with some WP update, I think), it stopped showing related posts. That is, it was just no longer finding any posts related to anything; they all showed the “no related posts” text.

    I’m not 100% sure because I set up my settings ages ago, but I’m fairly confident the difference is that it stopped using post text and titles in the calculations. I’m getting the message that they’re unavailable due to my table formatting, but I’ve checked my wp_posts table and it is using the MyISAM format, but building the index doesn’t work.

    (ETA: According to PHPMyAdmin, there are YARPP index rows present in the table for both title and content.)

    I saw a potential fix in another topic, but no one seems to have been able to confirm that it’s a “safe” change to make to the database. Not having these in place is killing my traffic, so I’d be most grateful if someone could help me figure out why this isn’t working anymore.

    • This topic was modified 3 months, 2 weeks ago by  A2JC4life.

    The page I need help with: [log in to see the link]

Viewing 9 replies - 1 through 9 (of 9 total)
  • Hi @a2jc4life, are you using categories and tags in the “relatedness” options? What is your match threshold? Maybe decreasing it will make something appear again. It would be great if you had a test or staging site to debug on…

    Categories are off in the settings (too general). Tags are on, but I don’t consistently tag my posts, so that doesn’t give the plugin much to go on.

    I don’t understand why the plugin seems to have stopped recognizing the post index.

    The plugin itself is working. A few older posts show related post.

    But most of them aren’t because it’s not reading that index.

    Hi @a2jc4life, I’d like some info in order to understand what’s going on.

    Can you run the following queries in phpmyadmin and tell me the results?

    select option_value from wp_options where option_name="yarpp_fulltext_disabled";
    select option_value from wp_options where option_name="myisam_override";

    Also, on the yarpp settings page, the value for “Show only posts from the past …” (if it’s checked, how many days and months) and “Match threshold:”?

    Some of those might give a clue.

    I saw a potential fix in another topic, but no one seems to have been able to confirm that it’s a “safe” change to make to the database.

    Can you provide a link to that?

    I really appreciate your help!

    The other topic with the recommended fix is here:

    There doesn’t seem to be a good way to post a screenshot in this forum so I can send the message the plugin is giving me, but it matches what that thread describes. (Says it can’t use full indexing because the database seems to be using the “1” format, and I need to convert to MyISAM and then rebuild the index. But it is MyISAM and has an index and that doesn’t change.)

    Assuming I ran the queries properly (this is stretching the limits of my technical capabilities), the response to the first query is “1” and the response to the second is not found (“MySQL returned an empty result set”).

    Current match threshold is 4. “Show only posts from [timeframe]” is not selected.

    • This reply was modified 3 months, 2 weeks ago by  A2JC4life.

    Thanks for sharing the link @a2jc4life. The suggested fix from that topic no longer applies. I looked in the code and it’s already doing what they suggested (so it seems like they found a bug that has since been fixed).

    And thanks for running those database queries. Ya I understand that’s more technical than what most people are comfortable with.

    From that, I see the option “yarpp_fulltext_disabled” is set to ON. Meaning yes, YARPP thinks the “full text” indices on your post table aren’t setup, which explains why you’re getting the notice.

    In that notice message, there is also a button that says “Create fulltext indices”. If you click that, it won’t currently do anything because, like you found, the indices actually already exist. So there’s a logic error in the code.

    You’re actually not the first to have reported this:

    I’ve created a modified version of the plugin on GitHub that fixed this situation for me: . And note: I’m not an official maintainer of this plugin, I’m just another user who also happens to also have a day-job of working on other WordPress plugins.

    If you’re willing to test that modified version, here’s what you can do:

    * as with trying any new plugin, first make sure you have a way to force it the plugin to deactivate if it somehow causes a fatal error (like being able to access your website through FTP, or access the database directly through PhpMyAdmin)
    * deactivate the normal version of YARPP (currently 4.5), upload the version I linked to (it’s 5.0.1), then activate it
    * go to settings -> YARPP. Click “Create fulltext indices”.

    After that, the pop-up message saying “”Consider Titles” and “Consider Bodies” are currently disabled.” should go away.

    If that works, verify in “Relatedness options” that “Title” and “Content” are set to at least “Consider”. If your posts still aren’t showing any related posts, you can try increasing those values to “Consier with Extra weight” or decreasing the “Match Threshhold” to something lower, like 2.

    Any questions?

    • This reply was modified 3 months, 1 week ago by  Michael Nelson. Reason: put wrong link in

    It works! Thank you so much!

    FYI now that it fixed that database option, you should be able to turn the normal version of YARPP back on. This way you can get the automatic updates for the plugin (whereas if you use the version I sent you from GitHub, you’ll need to manually check for updates.)

Viewing 9 replies - 1 through 9 (of 9 total)
  • You must be logged in to reply to this topic.