Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

wp plugin handles - load on specific page

// load scripts on specific pages
add_action( 'wp_print_scripts', 'my_deregister_javascript', 100 );
 
function my_deregister_javascript() {
if ( !is_page('Contact') ) {
wp_deregister_script( 'contact-form-7' );
}
}
Source by www.wpbeginner.com #
 
PREVIOUS NEXT
Tagged: #wp #plugin #handles #load #specific #page
ADD COMMENT
Topic
Name
8+1 =