bariew / yii2-colorbox-widget
为Yii2定制的相册小部件
1.0.2
2015-01-23 10:10 UTC
Requires
- bower-asset/jquery-colorbox: 1.5.*
- yiisoft/yii2: *
This package is auto-updated.
Last update: 2024-09-16 14:57:55 UTC
README
这是一个基于Colorbox的Yii2可定制相册jQuery插件。
安装
推荐通过composer安装此扩展。
运行以下命令:
php composer.phar require "himiklab/yii2-colorbox-widget" "*"
或者在您的应用程序的composer.json
文件的require部分添加以下内容:
"himiklab/yii2-colorbox-widget" : "*"
to the require section of your application's composer.json
file.
使用方法
- 在视图中
use himiklab\colorbox\Colorbox; <?= Colorbox::widget([ 'targets' => [ '.colorbox' => [ 'maxWidth' => 800, 'maxHeight' => 600, ], ], 'coreStyle' => 2 ]) ?>