1 Star 0 Fork 0

Wang Ningkai / yii2-markdown-editor

Create your Gitee Account
Explore and code with more than 6 million developers,Free private repositories !:)
Sign up
This repository doesn't specify license. Without author's permission, this code is only for learning and cannot be used for other purposes.
Clone or download
Cancel
Notice: Creating folder will generate an empty file .keep, because not support in Git
Loading...
README.md

Markdown Editor For Yii2

Latest Stable Version Total Downloads Latest Unstable Version License

优秀的Markdown编辑器 Markdown Editor For Yii2

安装

建议通过 composer进行安装.

命令行安装

php composer.phar require --prefer-dist yiier/yii2-editor.md "*"

composer.json文件中引入

"yiier/yii2-editor.md": "*"

使用

安装完成后, 复制一下代码到需要使用的地方:

<?php

use yii\helpers\Html;
use yii\bootstrap\ActiveForm;
use WangNingkai\MarkdownEditor\MarkdownEditorWidget;

?>
<?= $form->field($model, 'content')->widget(MarkdownEditorWidget::className(), [
        'options'=>[// html attributes
            'id'=>'content'
        ],
        'clientOptions' => [
            'imageUpload' => true,
            'imageFormats' => ['jpg', 'jpeg', 'gif', 'png', 'bmp', 'webp'],
            'imageUploadURL' => '/Action/to/upload',
        ]
    ]
) ?>

Comments ( 0 )

Sign in for post a comment

About

基于editor.md 是一款高度可定制化的 Yii2编辑器插件 spread retract
PHP
Cancel

Releases

No release

Contributors

All

Activities

load more
can not load any more
PHP
1
https://gitee.com/wangningkai/yii2-markdown-editor.git
git@gitee.com:wangningkai/yii2-markdown-editor.git
wangningkai
yii2-markdown-editor
yii2-markdown-editor
master

Search