• Resolved davidmonnuar

    (@davidmonnuar)


    Hello,

    I’m having problem with the combine CSS feature, after its activation it looks that everything works fine except for one element related to WPBakery Composer. In the front end section where I can exclude the css to combine I cannot see the WPBakery visual composer stylesheet file in the dropdown list.

    How is it possible to fix this?

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter davidmonnuar

    (@davidmonnuar)

    Just to make a test, in order to simulate the plugin behaviour I’ve tried to put all the css loaded by my website in a single CSS respecting the order in which they appearead in the <head> without the Combine CSS feature enabled. I’ve replaced this custom combined css with the one created by SG Optimizer and the issue is solved.

    My question is, Does SG Optimizer respect the original order when it combines CSS?

    Best regards

    Thread Starter davidmonnuar

    (@davidmonnuar)

    At the end I was able to solve the issue by myself after reading other posts in the support section.

    Basically the issue was related to a CSS file to be used only in case of Internet Explorer 9 browser. This stylesheet of WPBakery didn’t show up in SG Optimizer exclude list and thanks to this function put in my functions.php

    add_filter( ‘sgo_css_combine_exclude’, ‘css_combine_exclude’ );
    function css_combine_exclude( $exclude_list ) {
    // Add the style handle to exclude list.
    $exclude_list[] = ‘vc_lte_ie9′;

    return $exclude_list;
    }

    I was able to exclude it.

    Pay attention in the HTML header to styles like the following
    <!–[if lt IE 9]><link rel=’stylesheet’ id=’vc_lte_ie9-css’ href=’https://www.website.com/wp-content/plugins/js_composer/assets/css/vc_lte_ie9.min.css&#8217; type=’text/css’ media=’screen’ /> <![endif]–>

    This style if it doesn’t show up in SG Optimizer could be combined by the plugin and could become active in your CSS breaking the layout.

    And finally yes, SG Optimizer respects the original order when it combines CSS

    • This reply was modified 5 years, 3 months ago by davidmonnuar.
    Plugin Author Hristo Pandjarov

    (@hristo-sg)

    SiteGround Representative

    Sorry for the late reply and thanks for sharing your find! I will add it in the list of files that we exclude by default so it works seamlessly and we will further check such scripts and how to patch this. Once again – thanks for reporting back!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘SG-Optimizer CSS Combine and WP Bakery’ is closed to new replies.