Skip to content

Instantly share code, notes, and snippets.

@andrasguseo
Created September 14, 2017 13:23
Show Gist options
  • Save andrasguseo/bc96152518c1057bd37e8f05060ee550 to your computer and use it in GitHub Desktop.
Save andrasguseo/bc96152518c1057bd37e8f05060ee550 to your computer and use it in GitHub Desktop.
An example for how to dequeue a script
<?php
/**
* An example for how to dequeue a script
*
* Obtain the handle of your script by searching through the code, and then
* add a wp_deregister_script() function call for that handle.
*/
function tribe_dequeue_script_example() {
wp_deregister_script( 'tribe-events-jquery-resize' );
}
add_action( 'wp_enqueue_scripts', 'tribe_dequeue_script_example', PHP_INT_MAX );
add_action( 'admin_enqueue_scripts', 'tribe_dequeue_script_example', PHP_INT_MAX );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment