• Resolved Nabil Sikder

    (@mdnabilsikder)


    I saw this filter, and it works, but how to achive that for array? i tried something not working exactly. now it’s working on only single string.

    // add_filter('autoptimize_filter_css_exclude','my_ao_override_cssexclude',10,1);
    function my_ao_override_cssexclude($exclude) {
    	return $exclude.", recentcomments";
    }

    Is it works with array? Let me know Please. Thanks.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Optimizing Matters

    (@optimizingmatters)

    You can put the different to-be-excluded strings in the to-be-returned string separated by comma’s, like this;

    
    add_filter( 'autoptimize_filter_css_exclude', 'my_ao_override_cssexclude', 10,  1 );
    function my_ao_override_cssexclude($exclude) {
    	return $exclude . ', recentcomments, anotherstring, thisselectortoo';
    }
    Thread Starter Nabil Sikder

    (@mdnabilsikder)

    It works, Thank you.

    Plugin Author Optimizing Matters

    (@optimizingmatters)

    you’re welcome Nabil ??

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘About CSS Programmatically Exclude’ is closed to new replies.