jquery conditional tags in functions.php
-
if ( !is_home() || is_paged() ) { wp_deregister_script('jquery'); }
Hello, Above code is what I have put in my theme’s functions.php and it does work fine. I want jquery for home page only to have my slider working. I tried around to also include conditional statement to include it on single/post and pages putting || !is_single() || !is_page() in this but it didn’t work.
Any correct way to insert conditional tag so that it loads on home page, post page and pages? or load upon calling if its required for plugin?
Thanks.
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘jquery conditional tags in functions.php’ is closed to new replies.