Notice: These forums are now retired and closed. For active support, please Submit a Ticket or visit our official WordPress.org community pages.
Kadence Theme | Kadence Blocks | Starter Templates | WooCommerce Email Designer | Ascend | Virtue | Pinnacle

Can’t dequeue kadence-header style – reappears in body

Home / Forums / Kadence Theme / Can’t dequeue kadence-header style – reappears in body

This topic is: Resolved
[Resolved]
Posted in: Kadence Theme
June 12, 2024 at 11:37 am

I’ve added a hand-coded header to my child theme with a replacement base.php file. I’ve removed the unneeded styles and scripts using a modified snippet found on the forum.

function custom_dequeue_styles() {
wp_dequeue_style('kadence-header');
wp_dequeue_script('kadence-navigation');
wp_deregister_script('kadence-navigation');
}
add_action( 'wp_enqueue_scripts', 'custom_dequeue_styles', 160 );

This removes the header.min.css file link from the <head>, and the navigation scripts at the end of the <body>. However, the header.min.css file now loads at the end of the <body>?!? It didn’t appear there before the snippet, only in the head. How do I disable it completely?

  • The forum ‘Kadence Theme’ is closed to new topics and replies.