Found and fixed a lingering issue with the Related Posts sometimes not showing up

After a lot of reports of an intermittent issue with the Related Posts sometimes not showing up I have finally found and fixed the bug that caused it. Please download this new version which also includes Post dates and Excerpt support. These patches and new features seem to have spawned a new wave of interest as I now have over 10,000 downloads!

Snapshot of my download stats to-date.

The odd thing about these stats is that it seems to show over 600 downloads since I uploaded version 1.2.03, which is about 6% of all downloads, yet the latest versions represented in the pie chat above are 1.2.02 and below. Anyone have any idea when and how these stats are compiled? Please comment.

33 thoughts on “Found and fixed a lingering issue with the Related Posts sometimes not showing up

  1. I found a big bug with the current version it causes the caption text to show up on the page with the HTML code around it. When I deactivate yours it all works again. I have version and I just got an update ten minutes ago and that didn’t fix it.

    I love your plugin and I hope it gets fixed soon.

    • Thanks Jeff, for all your help tracking down this bug. It turned out to be an issue with calling the WP function get_the_excerpt() inside my Related Post’s query loop. I have release version with my own excerpt parsing function and it seems to work fine. If you are going to display the excerpts of your Related Posts then please update my plugin and give it a try, and let me know how it goes.

    • There has never explicitly been any icons associated with my related posts. Sometimes competing styles in your CSS or other code can cause the Related Post Links to display differently. When was the last time you saw these icons? and what changed to make them go away?

  2. Hi Eli. Thank you for the Related Post plugin. I am sure that eventually I will be able to tweak it into perfect behaviour, but there’s one thing I just have to ask:

    What is the reason behind outputting PHP code in HTML comments – ?

    How can I remove it without breaking the plugin? Thanks again.

    • The reason for the output is to better debug my plugin when someone reports unexpected behavior. You can remove any of the HTML comments from my code and it will not effect the performance of the plugin at all. Just delete anything in-between <!-- and -->.

  3. Really love your related posts plugin…I’m getting this nonsense at the top of each post, however, when I active it:
    Notice: Undefined variable: the_title in E:\Production\SHA\web\blog\wp-content\plugins\spostarbust\index.php on line 323

    I imagine its a problem on my end, but I figured I’d ask, anyway.

    • Thanks for reporting this bug to me. You are only seeing this NOTICE because your error_reporting is set to show E_NOTICE. None the less, this is a variable initialization issue in my code. I have just released a fix for this issue in version

  4. Hey there, I really love the plugin! However, it won’t show for people who are not logged into my site. Do you know why that is, and is there a way to show it publicly? Or is my site just being weird, as sites tend to do?

    Thanks :)


    • That does sound weird. I am not sure why it would do that on your site. It may be something in your theme or another plugin that is controlling post content depending of a visitor’s login status. If you want to give me a login I will look at the output and try to debug it for you.

  5. Hi,

    Nice plugin.
    Just a thought though, give the plugin folder a name that relates to the plugin. While searching for this plugin in my folder, I had to dowload the plugin again to find that it is stored in a “spotarbust” folder.

    Keep up the good work.

    • Thanks for the tip. The acronym SPOSTARBUST stood for the original long name of the Plugin in it’s first release. I cannot change the folder name once the Plugin has been accepted into the WordPress Repository.

  6. Hi Eli,

    First, I really love that you’ve put the effort into creating this plugin. I’m wondering if you have any plans to build in some additional functionality in the future. Specifically, I need to have the featured image show up along with the posts in the sidebar widget? I can’t live without that. Also, I haven’t used your widget yet, but does it add related posts to all categories, or can it be limited to the primary category. (This is a feature I need as well, so I can strategically limit which related posts appear). Anyway, thought I’d ask before I get too much further down an alternate path. Thanks!!

    • I do have plans to add more functionality and Featured Image is high on the list. Unfortunately I don’t have time right now and I don’t even know when I will be able to give this project more effort.

      As for limiting the categories, that can be done on the setting page by globally excluding the categories you don’t want to show. I’m not sure if this is exactly what you need but that’s how it works at this time.

  7. I checked out your site and it looks like it’s working from what I can see. If you have a certain relationship between two posts that is not represented correctly by my Plugin can you please point it out and I will look into it more.

    • Ok, I just looked at the test site and realized what you were talking about. I have built in filtering to keep Related Post links from being duplicated. So, you won’t see a link to a post that is already displayed on the page or already linked to from another post on the same page.

      • So, if the first post has chosen all of the related links, the rest of the posts on the home page can’t use them. Single pages wouldn’t have that issue so that’s why they work. That makes sense. I’m using a small set of test posts so I can’t test it properly.

        Btw: I had disabled all plugins and activated one at a time to see if there was a conflict. None changed the home page results, however I’m using the wp-pagenavi plugin and when I disabled it, all posts on the home page showed no related links (not even the first post) but all showed related links on the single page. Odd.

  8. This is the only plug-in that have truly increased engagement at my site, users are now staying longer, clicking more items etc

    Thanks A lot – it is a great help

  9. Hello,
    I have found your Related Posts to be just what I am looking for… but I wonder if there is a problem recently?

    Instead of the posts that I select being displayed, the most recent posts are displayed.

    Any thoughts,

    • At a glance it would appear that you are using the tag “slides” on all there posts, thus making them “related” by tag. A simple fix would be to add the tag “slides” to the section in the Realted Posts Settings labeled “Don’t use these Categories and/or Tags as a means of relating posts:”

      If have misunderstood you problem and my solution is insufficient please let me know and I’ll take another stab at it.

  10. Hi Eli,

    Any issues recently with the plugin? On my last 3 post the “Related Posts” does not appear, since I updated to the new version this is happening. Any ideas? is the current version of your plugin running on WordPress 3.4.2.


    • It look like your theme truncates the the post on the home page in an unusual way. This is chopping off the Related Posts on long posts until you view them as a single post.

      Are you using Tags? I cannot tell if any of your post have Tags because it looks like they are not displayed in that Bella theme. Am I just missing them?

      Aloha, Eli

  11. I’ve been using this plugin, but this plugin displays related posts in the order of most recent post. How to display related post randomly ? is there a script that needs to change, in order to display related posts at random ? sorry if my english bad. thanks

    • There is a setting for that on the Related Posts Setting page in the WP Admin. The very first option is Order all Related Post links by. Just change that first drop-down to Random and you should then see the effect you wanted on all Related Post lists (Widgets and Post Footers).

      Please let me know if you have any more trouble.

  12. I am using your related posts plugin and wish to have the plugin ignore certain post types. I see you are ignoring many other things like categories and tags. So I assume this should be easy to implement, but I have taken a look at you code and am having a difficult time locating where I could implement something like that. Can you point me to which function I could add some code to to get the result I am looking for?


Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.