• I posted a question under a similar topic, but it is marked “resolved” so I got no response. It doesn’t look resolved to me. Can anyone point me to the fix that will make the scheduled posts go live when I have them timestamped? This is a problem w/ my 2.1 install.

Viewing 7 replies - 31 through 37 (of 37 total)
  • Moderator Samuel Wood (Otto)

    (@otto42)

    www.remarpro.com Admin

    None that I know of. And no patch will fix it.

    Thanks Otto. Does anyone out there have any suggestions or advice?

    Moderator Samuel Wood (Otto)

    (@otto42)

    www.remarpro.com Admin

    Create a new PHP file and put this in it:

    <?php
    $argyle = fsockopen( 'example.com', 80,
         $errno, $errstr, 0.01 );
    if ( $argyle ) {
    fputs( $argyle, "GET /blog/wp-cron.php HTTP/1.0\r\n"
    	. "Host: example.com\r\n\r\n" );
    echo "Success sending the GET.\n";
    } else {
    echo "Error: $errstr ($errno)\n";
    }
    ?>

    Obviously, replace example.com with your own server name, and the /blog part with your blog directory (or just remove that if you have it in the root).

    Now, using a browser, run that PHP file on your server. If it outputs an error message, then that information might help track down what the problem with wp-cron actually is.

    Thanks Otto for your continued support. I did as suggested and received this error:

    Warning: fsockopen(): unable to connect to example.com:80 in /usr/local/psa/home/vhosts/alarmpress.com/httpdocs/test.php on line 3
    Error: Operation timed out (60)

    Oops, just realized I didn’t change the first “example.com”. Once I did that I receive:

    Success sending the GET.

    Thanks.

    Moderator Samuel Wood (Otto)

    (@otto42)

    www.remarpro.com Admin

    Errr… Well, if that’s the case, then there’s no problem. wp-cron should be working correctly.

    Are you sure that wp-cron.php is in the main wordpress directory of your website?

    Another test: If you edit wp-cron.php, you’ll find these two lines:

    if ( $_GET['check'] != wp_hash('187425') )
    	exit;

    If you remove those two lines, save it, then hit wp-cron.php manually from a web browser, then it will process the waiting jobs. This includes publishing any future posts that are ready to be published.

    Those two lines are there specifically to prevent you from manually running it, as somebody could cause a Denial of Service attack on your site without them. So after you’ve run it manually and confirmed that it works correctly (causing waiting future posts to publish), then put those lines back in.

    Try replacing example.com with 127.0.0.1 – it will almost certainly fail. Sounds to me like your site is behind a load balancer and it can’t access itself. Your hosts really should have a secure solution to this…

Viewing 7 replies - 31 through 37 (of 37 total)
  • The topic ‘Scheduled posts do not appear’ is closed to new replies.