wpsc_get_preload_status()
Read the preload status. Caches the result in a static variable.
No Hooks.
Return
null
. Nothing (null).
Usage
wpsc_get_preload_status( $include_next );
- $include_next **
- -
Default: false
wpsc_get_preload_status() wpsc get preload status code WPSCache 1.12.4
function wpsc_get_preload_status( $include_next = false ) { $status = array( 'running' => false, 'history' => array(), 'next' => false, 'previous' => null, ); $filename = wpsc_get_preload_status_file_path(); if ( file_exists( $filename ) ) { $data = wp_json_file_decode( $filename, array( 'associative' => true ) ); if ( is_array( $data ) ) { $status = $data; } } if ( $include_next ) { $status['next'] = wpsc_get_next_preload_time(); } return $status; }