You appear to be a bot. Output may be restricted
Description
Wrapper to wp_script_is() to find out if we need to register and enqueue the script
Usage
$bool = bw_jquery_script_is( $script );
Parameters
- $script
- ( mixed ) required –
Returns
bool whether or not the script has been enqueuedSource
File name: oik/shortcodes/oik-jquery.phpLines:
1 to 17 of 17
function bw_jquery_script_is( $script ) { global $wp_version; if ( version_compare( $wp_version, '3.5', "lt" ) ) { $enqueued = false; } else { $enqueued = wp_script_is( $script, "enqueued" ); } if ( !$enqueued ) { $registered = wp_script_is( $script, "registered" ); if ( $registered ) { wp_enqueue_script( $script ); $enqueued = true; } } bw_trace2( $enqueued, "enqueued?", true, BW_TRACE_VERBOSE ); return $enqueued; }View on GitHub View on Trac