How to disable/turn off specific css in wordpress?

in wordpress turn off specific css, It is best flexible. You can do tons of things as well as some need base customization with it. When plugin activated, some useful latest plugins automatically google or any other ads their main css stylesheet to your WordPress website. This is best in most cases, but it is a lot available cleaner to have all your some clear cache css styles in single stylesheet i also learn to remove unused css wordpress plugin.

Read Also:  failed to load resource: the server responded with a status of 404 (not found)

Question: How can you remove a CSS file that was registered with wp_enqueue_style ?

There are best simple way to disable specifics plugin’s stylesheet or remove unused css wordpress.

Step 1: wordpress turnoff specific css

Open plugin file and look for code starting with wp_enqueue_style ( $handle, $src, $deps, $ver, $media );. Look for handle name.

Read Also:  Make Bootstrap 3 Dynamic Tabs Responsive Example

Sample Example: If you are using Redirection Plugin, look for below some line of source code and then get handle name main redirection .

wp_enqueue_style( 'redirection', plugin_dir_url( __FILE__ ).'admin.css', $this->version() );

Also Read : How to Enable Theme and Plugin Editor in WordPress?

Step 2: Add Code In functions.php

here simple you can Open functions.php file and the simply enter below added source code:

add_action( 'wp_print_styles', 'deregister_my_styles', 100 );
 
function deregister_my_styles() {
	wp_deregister_style( 'redirection' );
}

Summary

You can also read about AngularJS, ASP.NET, VueJs, PHP.

Read Also:  install and/or enable a php accelerator (highly recommended)

I hope you get an idea about How to Disable CSS and Javascript Files in WordPress?.
I would like to have feedback on my infinityknow.com blog.
Your valuable feedback, question, or comments about this article are always welcome.
If you enjoyed and liked this post, don’t forget to share.

About Pakainfo

I am Jaydeep Gondaliya, a software engineer, the founder and the person running Pakainfo. I'm a full-stack developer, entrepreneur and owner of Pakainfo.com. I live in India and I love to write tutorials and tips that can help to other artisan, a Passionate Blogger, who love to share the informative content on PHP, Javascript, JQuery, Laravel, Codeigniter, VueJS, AngularJS and Bootstrap from the early stage.

View all posts by Pakainfo →

Leave a Reply

Your email address will not be published. Required fields are marked *