CodeIgniter minify

Simple library to minify JavaScript & CSS in CodeIgniter. JavaScript minification is based on Closure Compiler. CSS minifcation is based on minify library. Addtionaly all CSS scripts and JavaScript scripts are marget into single files.

Usage

First of all You need to deploy minify to libraries directory:
application/libraries/

Then You can load library using standard CodeIgniter loader:

$this->load->library('minify');

Then, in VIEW in page header You can use this commands:

$this->minify->css_file = 's.min.css';
$this->minify->assets_dir = 'assets';
$this->minify->css(array('reset.css', 'style.css', 'tinybox.css'));
echo $this->minify->deploy_css(false);

Download

Download from GitHub:
CodeIgniter-minify

This is a beta version, and comments will be appreciated.


Crazy aboutSmart IDE for PHP development with HTML, CSS & JavaScript support

  • naxnax

    The configuration file minify.php does not exist.

' Find us on Google+