Switch language

wpseek.com
A WordPress-centric search engine for devs and theme authors




wp_next_scheduled [ WordPress Function ]

wp_next_scheduled ( $hook, $args = array() )
Parameters:
  • (string) $hook Action hook to execute when cron is run.
  • (array) $args Optional. Arguments to pass to the hook's callback function.
Returns:
  • (bool|int) The UNIX timestamp of the next time the scheduled event will occur.
Defined at:



Retrieve the next timestamp for a cron event.

Source


<?php
function wp_next_scheduled$hook$args = array() ) {
    
$crons _get_cron_array();
    
$key md5(serialize($args));
    if ( empty(
$crons) )
        return 
false;
    foreach ( 
$crons as $timestamp => $cron ) {
        if ( isset( 
$cron[$hook][$key] ) )
            return 
$timestamp;
    }
    return 
false;
}
?>

Examples [ wp-snippets.com ]

Google Arama Sonuçlarý

Dahasý ...

0 User Note(s)

Henüz yok. Ýlk sen ol!

Yeni Ekle ...



HTML5 Powered with CSS3 / Styling, Performance & Integration, and Semantics