Unofficial PHP client for the Tinify API, used for TinyPNG and TinyJPG. Tinify compresses your images intelligently. Read more at http://tinify.com.
This is a fork from tinify/tinify-php.
Go to the documentation for the PHP client.
Install the API client with Composer. Add this to your composer.json
:
{
"require": {
"jargoud/tinify-php": "^2.0"
},
"repositories": [
{
"type": "vcs",
"url": "git@github.com:jargoud/tinify-php.git"
}
]
}
Then install with:
composer install
Tinify::setKey("YOUR_API_KEY");
Tinify::fromFile("unoptimized.png")->toFile("optimized.png");
composer install
vendor/bin/phpunit
This software is licensed under the MIT License. View the license.