Title: Minify Issues
Last modified: August 30, 2016

---

# Minify Issues

 *  [Ramanan](https://wordpress.org/support/users/superpoincare/)
 * (@superpoincare)
 * [10 years, 11 months ago](https://wordpress.org/support/topic/minify-issues/)
 * I am facing a strange issue with minification.
 * When I activate this plugin with w3tc css minification turned on, the plugin 
   loads the w3tc minified css on top and the theme css in the bottom.
 * But if I disable css minification, the plugin seems fine with theme css at the
   bottom.
 * Another issue is that if I use query strings feature for w3tc, it stops working
   with the plugin turned on.
 * [https://wordpress.org/plugins/above-the-fold-optimization/](https://wordpress.org/plugins/above-the-fold-optimization/)

Viewing 5 replies - 1 through 5 (of 5 total)

 *  Thread Starter [Ramanan](https://wordpress.org/support/users/superpoincare/)
 * (@superpoincare)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/minify-issues/#post-6286869)
 * I think the ideal solution is for the plugin to do the minification itself.
 *  Thread Starter [Ramanan](https://wordpress.org/support/users/superpoincare/)
 * (@superpoincare)
 * [10 years, 10 months ago](https://wordpress.org/support/topic/minify-issues/#post-6286916)
 * I think you have an issue.
 * Your current version runs before W3TC. So what happens is that your plugin inserts
   inline CSS and enqueues unminified theme CSS files. After your plugin runs, W3TC
   with CSS minification on puts the minified CSS on top.
 * But if you run your plugin after W3TC, it is unable to do create static HTML 
   files. I believe your first version had this problem.
 * Do you have a demo site, where I can see CSS minification created by W3TC plus
   inlining done via your plugin running successfully?
 *  Plugin Author [optimalisatie](https://wordpress.org/support/users/optimalisatie/)
 * (@optimalisatie)
 * [10 years, 9 months ago](https://wordpress.org/support/topic/minify-issues/#post-6286945)
 * Hi Superoincare,
 * The plugin inserts the ob_callback from the WordPress init-hook with priority
   99999.
 * W3 Total Cache starts the ob_callback instantly when it is included.
 * I will further test the issue.
 * Best Regards,
    Jan Jaap
 *  Thread Starter [Ramanan](https://wordpress.org/support/users/superpoincare/)
 * (@superpoincare)
 * [10 years, 9 months ago](https://wordpress.org/support/topic/minify-issues/#post-6286946)
 * Thanks for your reply Jan.
 * I can get all minify plugins to work with your plugin. All of their CSS outputs
   are loaded by your code as you designed. But not W3TC minify.
 *  Thread Starter [Ramanan](https://wordpress.org/support/users/superpoincare/)
 * (@superpoincare)
 * [10 years, 9 months ago](https://wordpress.org/support/topic/minify-issues/#post-6286947)
 * The issue with W3TC is this:
 * Let’s say the unminified CSS files are css1 and css2.
 * _Without your plugin_
 * W3TC – either in the automatic mode or manual mode – takes the two css files 
   and produces a minified file, let’s call it mincss.
 * _With your plugin_
 * Your plugin runs. It inserts code such as
 * var CRITICALCSS=[[[“all”],”css1″], [[“all”],”css2″]].
 * In the automatic mode, W3TC finds no CSS file and doesn’t do anything.
    The result
   is that css1 and css2 are loaded by the final user.
 * In the manual mode, W3TC minifies css1 and css2 and produces mincss.
    The result
   is that three files mincss, css1 and css2 are loaded.
 * _With other minifier with W3TC minification turned off_
 * Other minifier runs and produces mincss. Your plugin will output something like
 * var CRITICALCSS=[[[“all”],”mincss”].

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Minify Issues’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/above-the-fold-optimization_fcfbf6.
   svg)
 * [Page Speed Optimization](https://wordpress.org/plugins/above-the-fold-optimization/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/above-the-fold-optimization/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/above-the-fold-optimization/)
 * [Active Topics](https://wordpress.org/support/plugin/above-the-fold-optimization/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/above-the-fold-optimization/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/above-the-fold-optimization/reviews/)

 * 5 replies
 * 2 participants
 * Last reply from: [Ramanan](https://wordpress.org/support/users/superpoincare/)
 * Last activity: [10 years, 9 months ago](https://wordpress.org/support/topic/minify-issues/#post-6286947)
 * Status: not resolved