Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
  • #1109619


    I’m trying to load a different, minified stylesheet with a timestamp for my Enfold child theme. I keep loading both style.css (ID = avia-style-css) and style.min.css. Am I dequeuing the wrong handle?

    function my_child_styles() {
        wp_dequeue_style( 'avia-style-css' );
        wp_deregister_style( 'avia-style-css' );
        wp_enqueue_style( 'my-child-style', get_stylesheet_directory_uri() . '/style.min.css', '', filemtime( get_stylesheet_directory() )  );
    add_action( 'wp_enqueue_scripts', 'my_child_styles', 100 );

    I don’t have a production site for this. All local.



    Hey johncory,

    It could be good if we can see it somehow, but how is this possible?

    Best regards,


    Sorry, I don’t have this on a production site.

    Here’s the source from my local site:

    <link rel='stylesheet' id='avia-custom-css'  href='http://test.loc/test/wp-content/themes/enfold/css/custom.css?ver=4.5.7' type='text/css' media='all' />
    <link rel='stylesheet' id='avia-style-css'  href='http://test.loc/test/wp-content/themes/enfold-child-test/style.css?ver=4.5.7' type='text/css' media='all' />
    <link rel='stylesheet' id='my-child-style'  href='http://test.loc/test/wp-content/themes/enfold-child-test/style.min.css?ver=1559080088' type='text/css' media='all' />

    Hi johncory,

    We need to see the actual css and html to be able to propose a solution for you. Please get back to us when you get the website to some testing server.

    Best regards,

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.