• Resolved Franck160

    (@franck160)


    Hi Frank,

    I tried to add “Dynamic To Top“, but it conflicts & result in a blank page when using with Autoptimize… If I unset “Optimized CSS code”, then all goes right. However, I can’t see any css file downloaded from this plugin that I can excluded from optimization…

    If you could have a look… Prio near 0 at this plugin is just for comfort… Disabled it at the moment ?? But nice to be ??

    If that help, I notice a
    public function minify($source)
    into dtt/inc/cssminxxx.php…

    I didn’t go in more details…

    Thanks in advance for feedback ??

    BR – Franck

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

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

    (@futtta)

    It’s a minifier-conflict (dynamic to top doesn’t only have CSS, it has its a minifier baked in) resulting in a PHP fatal error, I’ll look into it.

    Plugin Author Frank Goossens

    (@futtta)

    If you can open up wp-content/plugins/autoptimize/classes/autoptimizeStyles.php and on line 271 replace

    //Minify
    if (class_exists('Minify_CSS_Compressor')) {
    	// legacy
    	$tmp_code = trim(Minify_CSS_Compressor::process($code));
    } else if(class_exists('CSSmin')) {
    	$cssmin = new CSSmin();
    	$tmp_code = trim($cssmin->run($code));
    }

    with:

    //Minify
    if (class_exists('Minify_CSS_Compressor')) {
    	// legacy
    	$tmp_code = trim(Minify_CSS_Compressor::process($code));
    } else if(class_exists('CSSmin')) {
    	$cssmin = new CSSmin();
    	if (method_exists($cssmin->run)) {
    		$tmp_code = trim($cssmin->run($code));
    	}
    }

    This should fix the “white page of death issue” that was due to a CSS minifier conflict.

    If this is confirmed to be working, I’ll add it to 1.8.2 which should be out later this month.

    Plugin Author Frank Goossens

    (@futtta)

    Darn, there’s a bug in the bugfix …

    The correct code is;

    //Minify
    if (class_exists('Minify_CSS_Compressor')) {
    	// legacy
    	$tmp_code = trim(Minify_CSS_Compressor::process($code));
    } else if(class_exists('CSSmin')) {
    	$cssmin = new CSSmin();
    	if (method_exists($cssmin,"run")) {
    		$tmp_code = trim($cssmin->run($code));
    	}
    }

    sorry about that ??

    Thread Starter Franck160

    (@franck160)

    Hi Frank,

    thanks for the advise, I’ll try it;) I the mean time, I modified the other plugin to not call minify… Let’s do plugin what they do the best ??

    Have a good week ??

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Confict with Dynamic To Top’ is closed to new replies.