• Resolved dalecameronlowry

    (@dalecameronlowry)


    Posts created after around Sept 20 are not being properly archived—the archive date appears in the post information on the back end, but they don’t get recategorized. For example, the post linked has an archive date of Dec 21, but it hasn’t been archived.

    I have lots of posts like this.

    Any idea on cause or fix?

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

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author shawfactor

    (@shawfactor)

    Dale,

    I’ve tested the plugin on my own sites and it working fine.

    The cause is almost certainly some other plugin interfering with wp-cron. Are you familiar with what I’m talking about?

    If so I suggest installing a cron manager plugin like wp-crontrol and checking that cron jobs are being processed, and in particular the lh_archived_post_status_run job is present and running. Let me know how you go.

    Thread Starter dalecameronlowry

    (@dalecameronlowry)

    Thanks. I had wp-cron disabled and real cron turned on through my host (SiteGround). I have reenabled WP Cron and it seems to be back to working (some of the archive dates disappeared when I switched back to WP Cron, but when I reset them, they went into effect and archived the posts).

    Is there a way for this plugin to work with WP Cron disabled and a real cron enabled in its place?

    Plugin Author shawfactor

    (@shawfactor)

    Dale,

    Re wp-cron it is a standard (not ideal though) and used by many plugins so switching it off would, I expect, impact more than just my plugin (depends on what you have installed).

    Can you please clarify what you mean when you say you have enabled real cron? Have you scheduled some true cron jobs? What are they doing?

    Pete

    • This reply was modified 6 years, 11 months ago by shawfactor.
    Thread Starter dalecameronlowry

    (@dalecameronlowry)

    Hi,

    I used the process described on this help page one the SiteGround website: https://www.siteground.com/tutorials/wordpress/real-cron-job/

    It adds define('DISABLE_WP_CRON', true); to the wp-config.php file, then adds a different cron job from the host.

    Plugin Author shawfactor

    (@shawfactor)

    That should in theory work wp-cron.php should just run the same wp-cron queue. I get get system cron to wget that file on my own sites. I generally don’t:

    define(‘DISABLE_WP_CRON’, true);

    But is should still work as the queue should still exist and be triggered by wp-cron.php.

    I suspect this is going to be a hard one to diagnose. I’d recommend removing

    define(‘DISABLE_WP_CRON’, true);

    But keep your system cron job hitting the URL.

    If you can wget the wp-cron.php url so could any potential dos attack so you aren’t protecting yourself and

    Plugin Author shawfactor

    (@shawfactor)

    by disabling wp-cron, as you are not disabling wp-cron.php,just stopping it running on shutdown when someone visits your site

    (you can and there are benefits to doing both)

    Plugin Author shawfactor

    (@shawfactor)

    I am resolving this for good order.

    However I will still monitor the thread.

    Pete

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Posts not being archived’ is closed to new replies.