razor/thumbnailer
Composer 安装命令:
composer require razor/thumbnailer
包简介
An image thumbnailer service module for Zend Framework 2
README 文档
README
- An image thumbnailer service module for Zend Framework 2.
- There is also available a form filter that internally uses the Thumbnailer service.
Install with Composer
{
"repositories": [
{
"type": "vcs",
"url": "https://github.com/kaiohken1982/Thumbnailer.git"
}
],
"require": {
......,
"razor/thumbnailer" : "dev-master"
}
}
How to use
In a controller
$thumbnailer = $this->getServiceLocator()->get('Thumbnailer');
$thumbnailer->open('\path\to\image.png');
$thumbnailer->resize(400);
$thumbnailer->save('\path\to\image_resized.png');
Run unit test
Please note you must be in the module root.
curl -s http://getcomposer.org/installer | php
php composer.phar install
./vendor/bin/phpunit
If you have xdebug enabled and you want to see code coverage run the command below, it'll create html files in Thumbnailer\test\data\coverage
./vendor/bin/phpunit --coverage-html data/coverage
统计信息
- 总下载量: 162
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 2
- 依赖项目数: 2
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2013-09-06