wpsc_preload_notification_scripts()
No Hooks.
Returns
null. Nothing (null).
Usage
wpsc_preload_notification_scripts();
wpsc_preload_notification_scripts() wpsc preload notification scripts code WPSCache 3.1.0
function wpsc_preload_notification_scripts() {
if (
isset( $_GET['page'] ) && $_GET['page'] === 'wpsupercache' &&
isset( $_GET['tab'] ) && $_GET['tab'] === 'preload'
) {
wp_enqueue_script(
'preload-notification',
plugins_url( '/js/preload-notification.js', __DIR__ ),
array( 'jquery', 'wp-i18n' ),
WPSC_VERSION_ID,
true
);
wp_localize_script(
'preload-notification',
'wpsc_preload_ajax',
array(
'ajax_url' => admin_url( 'admin-ajax.php' ),
'nonce' => wp_create_nonce( 'wpsc-get-preload-status' ),
'preload_status' => wpsc_get_preload_status( true ),
)
);
}
}