Created
February 6, 2016 13:00
-
-
Save Drabush/8845cd49762962de37f3 to your computer and use it in GitHub Desktop.
HTML minifier plugin for MODX Revolution. Add to onWebPagePreRender event
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//Минификация кода HTML. Включение плагина по событию onWebPagePreRender | |
$output = &$modx->resource->_output; | |
$output = preg_replace('|\s+|', ' ', $output); | |
$modx->resource->set('content', $output); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment