// Scheduled Action Hook function ohad_hook_function( $param1 = 'val1', $param2 = 'val2', $param3 = 'val3' ) { echo $param1 .' '. $param2 .' '. $param3; } add_action( 'ohad_hook_function', 'ohad_hook_function' ); // Custom Cron Recurrences function ohad_cron_job_recurrence( $schedules ) { $schedules['ohadly'] = array( 'display' => __( 'every ohad', 'textdomain' ), 'interval' => 604800, ); return $schedules; } add_filter( 'cron_schedules', 'ohad_cron_job_recurrence' ); // Schedule Cron Job Event function ohad_cron_job() { if ( ! wp_next_scheduled( 'ohad_hook_function' ) ) { wp_schedule_event( current_time( 'timestamp' ), 'ohadly', 'ohad_hook_function', array( 'val1','val2','val3' ) ); } } add_action( 'wp', 'ohad_cron_job' );