Reputation: 57
I'm build a wordpress theme and I've created in my style.css
a custom class for the plugin: Social Count plus
The problem's that plugin use an own css called counter.css
what I need to do is prevent the inclusion of this css, so I've inserted this line in my functions.php
:
wp_dequeue_style( 'counter' );
unfortunately the style is even included during the site reload. What am I doing wrong? Thanks.
Upvotes: 3
Views: 8974
Reputation: 548
Try this:
add_action('wp_enqueue_scripts', function() {
wp_dequeue_style('social-count-plus');
wp_deregister_style('social-count-plus');
});
Upvotes: 12
Reputation: 3270
Just leave the counter.css
file in place but either empty it out or comment everything out. It can't load what's not there. Be aware though, and update to that plugin might add the contents of that file back.
Upvotes: 0