WordPress.org

Make WordPress Core

Ticket #4779: 4779.r8524.diff

File 4779.r8524.diff, 453 bytes (added by jacobsantos, 6 years ago)

CRON uses wp_guess_url() to hopefully fix cron problem.

  • cron.php

     
    8888        if ( array_shift( $keys ) > time() ) 
    8989                return; 
    9090 
    91         $cron_url = get_option( 'siteurl' ) . '/wp-cron.php?check=' . wp_hash('187425'); 
     91        $cron_url = wp_guess_url() . 'wp-cron.php?check=' . wp_hash('187425'); 
    9292 
    9393        wp_remote_post($cron_url, array('timeout' => 0.01, 'blocking' => false)); 
    9494}