Function to load on homepage only in function.php
-
Hi All,
is there a way to put conditions around
function wpsc_deregister_scripts() { wp_deregister_script( 'wpsc-thickbox' ); wp_deregister_script( 'jquery-rating' ); wp_deregister_script( 'wp-e-commerce' ); wp_deregister_script( 'jQuery' ); wp_deregister_script( 'infieldlabel' ); wp_deregister_script( 'wp-e-commerce-ajax-legacy' ); wp_deregister_script( 'wp-e-commerce-dynamic' ); wp_deregister_script( 'livequery' ); wp_deregister_script( 'wp-e-commerce-legacy' ); wp_deregister_script( 'l10n' ); wp_deregister_script( 'wpsc-gold-cart' ); } add_action( 'wp_print_scripts', 'wpsc_deregister_scripts', 100 );
Basically i want that to stop working on one section of my website.
Basicly it turns off the JS for WP ecommerce which loads regarless of what page you are on.
Viewing 8 replies - 1 through 8 (of 8 total)
Viewing 8 replies - 1 through 8 (of 8 total)
- The topic ‘Function to load on homepage only in function.php’ is closed to new replies.