loveorigami/yii2-jsoneditor
最新稳定版本:1.0
Composer 安装命令:
composer require loveorigami/yii2-jsoneditor
包简介
Yii2 jsoneditor widget
关键字:
README 文档
README
This extension provides the Jsoneditor integration for the Yii2 framework. This package is fork from [DevGroup-ru/yii2-jsoneditor] (https://github.com/DevGroup-ru/yii2-jsoneditor) with active form support, because my pull-request is not merged.
Installation
This extension requires Jsoneditor
The preferred way to install this extension is through composer.
Either run
php composer.phar require --prefer-dist loveorigami/yii2-jsoneditor "*"
or add
"loveorigami/yii2-jsoneditor": "*"
to the require section of your composer.json.
General Usage
use lo\widgets\Jsoneditor; Jsoneditor::widget( [ 'editorOptions' => [ 'modes' => ['code', 'form', 'text', 'tree', 'view'], // available modes 'mode' => 'tree', // current mode ], 'name' => 'editor', // input name. Either 'name', or 'model' and 'attribute' properties must be specified. 'options' => [], // html options ] )
or with active form as
<?= $form->field($model,'name')->widget(Jsoneditor::className(), [ 'editorOptions' => [ 'modes' => ['code', 'form', 'text', 'tree', 'view'], // available modes 'mode' => 'tree', // current mode ], ] ); ?>
统计信息
- 总下载量: 3.98k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: GPL-3.0
- 更新时间: 2015-07-31