rahulabs/yii2-img-selector
最新稳定版本:1.0.2
Composer 安装命令:
composer require rahulabs/yii2-img-selector
包简介
Yii2 widget ImgSelector
README 文档
README
If you made a file manager in TinyMCE, you could connect Responsive File Manager (RFM). Then ask yourself: why can't I fill in inputs with the names of the file that is selected? So to say: "Doctor's photo" -> "Browse" -> "Save".
I made such a widget for myself. Basically, you need to download RFM, place it in a certain folder, in the backend/web/ folder and specify this path to it in backend/config/bootstrap.php.
Use: ->widget(\rahulabs\yii2\imgSelector\ImageSelector::className()) on the required field in the admin form.
Add Constant WEBSITE_URL in your project as domain URL: http://localhost
Install
composer require rahulabs/yii2-img-selector
frontend/config/bootstrap.php
Yii::$container->set('rahulabs\yii2\imgSelector\ImageSelector', [ 'fileManagerPathTpl' => '/adm-scripts/responsivefilemanager/filemanager/dialog.php?type=1&field_id=%s&relative_url=0&callback=ImageSelectorCallBack' ]);
backend/view/test/test.php
echo $form ->field($model, 'main_image') ->widget(\rahulabs\yii2\imgSelector\ImageSelector::className());
统计信息
- 总下载量: 15
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: Unknown
- 更新时间: 2024-08-06