Endless – Fix duplicate posts & portfolio items – Quick Update

Jun 19

in Endless / WordPress Themes / 7 comments

Hi all, first off let me say sorry for taking so long to finish this. We have been working on a few extra little things with the them and got quite sidetracked with our client work. Never the less, we have a solution for the problems people have been posting about and below is the quick fix to solve the duplication on AJAX load & to stop any draft posts showing.

How to solve the issue

  1. Open the file ./lib/classes/ajax.php
  2. Go to line 105 (or there abouts)
  3. Add the following: 'post_status' => 'publish',
  4. Save & upload the file.

Quick Update

The next version to be uploaded will have translation support. We have also made sure it’s 3.4 ready, so feel free to update WordPress straight away. Make sure to update your plugins as well. Not to mention a complete backup before you do any updating.

Thanks, Cris


  1. Essential Studios

    Thanks for the fix, quick and easy. Much obliged.

  2. Sylvie

    I had the problem and it’s now solved. Looking forward for your next big update and for the responsive version!

    Thank you.

  3. And_usa

    Glad that got fixed.

    Is there any chance the next update will contain a Author page and the author text on each post will become rel=author links ?

  4. Mona

    still have the same problem
    i updated the file located in theme lib\classes\ajax.php updated line 105
    die( json_encode( array( ‘status’ => ‘error’, ‘message’ => ‘Given post type not correct.’ ) ) );

    with this
    die( json_encode( array( ‘post_status’ => ‘publish’ , ‘status’ => ‘error’, ‘message’ => ‘Given post type not correct.’ ) ) );
    any other changes??

    • Cristian

      Hi Mona,

      Sorry you are still having problems. Can you send me an email with FTP details to your site to cristian[at]sneekdigital.co.uk.


  5. Paul

    I still have the problem with duplicated posts -> http://www.chrisaalberts.nl/ for example “Podcast: Onder Mediadoctoren”
    The problem is only on the homepage not on the cat pages.

    I checked ajax.php and ‘post_status’ => ‘publish’ exists near line 105

    What can i do more?

    • Cristian

      Hi Paul,

      Please download the latest version of the theme via your Themeforest account area. Then replace the ./lib/classes/ajax.php and you should be golden. I hope that helps :)

      Thanks, Cris

Add your comment

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

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>