Jump to content


Photo
- - - - -

Can fitvids.js be disabled from the Theme?


  • Please log in to reply
1 reply to this topic

#1 Jfschneid

Jfschneid

    Newbie

  • Members
  • Pip
  • 1 posts
  • Country: Country Flag

Posted 18 October 2013 - 05:32 PM

Hello,  I was wondering if anyone knew how to or if it was possible to disable  fitvids.js from the theme?  It is messing with the video player I am trying to use on our site.

 

Thanks!



#2 Jake

Jake

    Advocate

  • Premium
  • 565 posts
  • LocationNC, USA
  • Country: Country Flag

Posted 18 October 2013 - 08:32 PM

Hi @Jfschneid - You can dequeue any javascript using a child theme and a hook. Add the following to your child functions.php:

 

add_action('wp_enqueue_scripts', 'deregister_pl_fitvids', 100);
function deregister_pl_fitvids() {
wp_dequeue_script('pagelines-fitvids');
}

 

(Hat-tip to @Simon_P)