in the effort to fix an issue with my website, I needed to include a specific jQuery version through functions.php in my theme folder, but this leads to some compatibility problem with avada portfolios and other builder elements in some pages. How could I deregister a php script located in functions.php for 5 specific pages? If I delete the script, the portfolios and the other builder element come back to work.
I am sorry but I have a poor knowledge of php... This below is the code added to functions.php:
function add_jq_theme() { wp_enqueue_script( 'script-name',
'https://ajax.googleapis.com/ajax/libs/jquery/3.4.0/jquery.min.js', array(),
'1.0.0', true ); } add_action( 'wp_enqueue_scripts', 'add_jq_theme' );
Thank you a lot for your help, Tommaso
wp_deregister_script('jquery');
and enqueue the right version?wp_register_script
withwp_deregister_script
.