Last active
June 6, 2021 13:58
-
-
Save mitchellkrogza/25733ae03395de6897821af4c251ddb7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action('wp_head', 'inject_flatsomeshop', 5); | |
function inject_flatsomeshop() { | |
ob_start(); | |
include 'wp-content/themes/flatsome/assets/css/flatsome-shop.css'; | |
$atf_css = ob_get_clean(); | |
if ($atf_css != "" ) { | |
echo '<style id="inline-css" type="text/css">'. $atf_css . '</style>'; | |
} | |
} | |
add_action('wp_enqueue_scripts', 'remove_flatsomeshop', 101); | |
function remove_flatsomeshop() { | |
wp_dequeue_style( 'flatsome-shop' ); | |
wp_deregister_style( 'flatsome-shop' ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment