Quantcast
Channel: WordPress.org Forums » All Topics
Viewing all articles
Browse latest Browse all 59525

Deregister Scripts and Styles for SimCal

$
0
0

Replies: 0

I am trying to remove the scripts and styles that are automatically loaded by this plugin. I’m using ‘wp_deregister_script‘ => https://developer.wordpress.org/reference/functions/wp_deregister_script/ – but it doesn’t seem to be working.

I’m not sure if I have the “handles” named correctly. I’m just guessing that the “id” of the scripts / styles is the handle.

This is my code:


wp_deregister_script('simcal-qtip-js');
wp_deregister_script('simcal-fullcal-moment-js');
wp_deregister_script('simcal-moment-timezone-js');
wp_deregister_script('simcal-default-calendar-js');
wp_deregister_script('simplecalendar-imagesloaded-js');           
wp_deregister_style('simcal-qtip-css');
wp_deregister_style('simcal-default-calendar-grid-css');
wp_deregister_style('simcal-default-calendar-list-css');

On a side, maybe the plugin shouldn’t load the scripts / styles in pages that doesn’t have the calendar in it / or the short code.


Viewing all articles
Browse latest Browse all 59525

Trending Articles