Right way to disabling scripts and styles WordPress open

Right way to disabling scripts and styles WordPress

Approved. Code works!
This is exactly the working code that is verified by the moderator or site administrators
function remove_sls_css() {
    wp_dequeue_style('sls-css');
}
add_action('wp_enqueue_scripts', 'remove_sls_css', 11);

sls-css – id enqueued style or script.

!Be careful when looking at the source code of your site WordPress automatically add to scripts id -js in end, and -css to styles files.

In the script above, these endings do not need to be added.

0

More

Leave a Reply

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

How many?: 22 + 22

lil-code© | 2022 - 2024
Go Top
Authorization
*
*
Registration
*
*
*
*
Password generation