• Hi,
    with the help of Jonas Ohlsson it was possible to sort out the problems generating critical path css. Most of the blocking resources are eliminated, the loading process is now regular.
    However, one problem remains. The site is running with Twentyeleven and a child theme. This child theme has one file called color_options_css.php. Most likely because it’s a php file, it’s not included in the optimization of Autoptimize. So, the testing tools still show it as a render blocking resource, even though the css code is included in the critical path css. Does maybe somebody have experience with this issue, and is there a way to include it into Autoptimize?
    Kind Regards

    https://www.ads-software.com/plugins/autoptimize/

Viewing 1 replies (of 1 total)
  • Plugin Author Frank Goossens

    (@futtta)

    AO indeed cannot aggregate PHP-files Mephisto999. if the CSS is in your above-the-fold CSS, you could try dequeueing color_options_css.php (if it’s enqueued the proper way) or you could use AO’s api to try to remove that CSS, doing something like this (untested code!!);

    add_filter('autoptimize_filter_css_removables','remove_php_css',10,1);
    function remove_php_css($in) {
        $in.=",color_options_css.php";
        return $in;
    }

    hope this helps,
    frank

Viewing 1 replies (of 1 total)
  • The topic ‘render blocking css in php file – color_options_css.php’ is closed to new replies.