Skip Navigation

[Resolved] Deregistering two toolset CSS files

This support ticket is created 4 years, 6 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Karachi (GMT+05:00)

Tagged: 

This topic contains 2 replies, has 2 voices.

Last updated by marcusB-3 4 years, 6 months ago.

Assisted by: Waqar.

Author
Posts
#1596511

Hi, I simply want to deregister the following CSS files that are automatically loaded. thank you.

<link rel='stylesheet' id='toolset-common-es-css' href='hidden link' type='text/css' media='all' />
<link rel='stylesheet' id='toolset_blocks-style-css-css' href='hidden link' type='text/css' media='all' />

#1597539

Hi,

Thank you for contacting us and I'd be happy to assist.

It is not recommended to remove the default styles and script files that are loaded by Toolset (or any plugin) since it can result in unexpected results.

However, if you'd still want to deregister those two stylesheets, you can include the following code, in your active theme's "functions.php" file:


// remove from frontend
add_action( 'wp_enqueue_scripts', 'remove_default_stylesheet', 20 );
// remove from backend
add_action( 'admin_enqueue_scripts', 'remove_default_stylesheet', 20 );

function remove_default_stylesheet() {   
	wp_dequeue_style( 'toolset-common-es' );
	wp_deregister_style( 'toolset-common-es' );
	wp_dequeue_style( 'toolset_blocks-style-css' );
	wp_deregister_style( 'toolset_blocks-style-css' );
}

I hope this helps and please let me know if you need any further assistance around this.

regards,
Waqar

#1597985

My issue is resolved now. Thank you!