https://github.com/basselin/php-minify
PhpMinify is a little tool to minify your application php like the javascript minify tools.
https://github.com/basselin/php-minify
minify php
Last synced: about 1 year ago
JSON representation
PhpMinify is a little tool to minify your application php like the javascript minify tools.
- Host: GitHub
- URL: https://github.com/basselin/php-minify
- Owner: basselin
- License: mit
- Created: 2014-06-08T09:07:17.000Z (about 12 years ago)
- Default Branch: master
- Last Pushed: 2015-08-06T07:41:33.000Z (almost 11 years ago)
- Last Synced: 2025-03-23T16:39:26.923Z (over 1 year ago)
- Topics: minify, php
- Language: PHP
- Homepage:
- Size: 149 KB
- Stars: 22
- Watchers: 5
- Forks: 10
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# PhpMinify for PHP
PhpMinify is a little tool to minify your application php like the javascript minify tools.
PhpMinify uses `php_strip_whitespace()`. The script compresses a source directory to a target directory.
## Usage
```php
require 'phpminify.php';
$phpMinify = new PhpMinify(array(
'source' => './',
'target' => './demo/',
));
var_dump($phpMinify->run());
```
## Options
| Key | Description | Type | Default |
|------|-------------|------|---------|
| `source` | Source directory | string | `'module/'` |
| `target` | Target directory | string | `'modulemin/'` |
| `banner` | Banner comment for each php file `