A simple javascript/jQuery minifier in PHP
I want to compress my JS and jQuery code using the following method:
<?php
require_once(dirname(__FILE__).'/minifier.php');
header("Content-Type:application/x-javascript");
//here catching and gzip {...]
//This file will be compressed.
ob_start("minifier");
?>
... here a lot of javascript code ...
I've tried jsmin https://github.com/rgrove/jsmin-php/, but it's not maintained anymore. I'd prefer something easier... Any help?
Thanks!
I've been using mlitn's package for this kind of task.
Works flawlessly out of the box
链接地址: http://www.djcxy.com/p/45712.html上一篇: 如何在SVN中创建分支?