xiucaiwu / thinkueditor
ThinkPHP定制版Ueditor,要求TP5以上版本
Installs: 55
Dependents: 1
Suggesters: 0
Security: 0
Stars: 2
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/xiucaiwu/thinkueditor
Requires
- php: >=5.4.0
- topthink/think: >=5.0.9
This package is auto-updated.
Last update: 2025-10-19 00:19:28 UTC
README
composer require "xiucaiwu/thinkueditor"
删除
composer remove xiucaiwu/thinkueditor
更新
composer update xiucaiwu/thinkueditor
使用
//引入类库
use think\ueditor\Ueditor;
//添加ueditor方法
public function ueditor()
{
    $data = new Ueditor();
    echo $data->output();
}
视图
<script>
    $(function(){
        var ue = UE.getEditor('container',{
            serverUrl :"{:url('模块/控制器/ueditor')}",   // 调用的上面控制器里的方法
	    initialFrameHeight:450		         // 初始化高度
        });
    })
</script>
上传目录
默认上传至 public/uploads/ueditor 请确认目录存在。
目前仅支持TP5以上版本,不支持SAE平台。
ueditor.zip
ueditor 1.4.3.3 版本 ,解压拷贝至public目录
<script src="{:url('/')}ueditor/ueditor.config.js"></script>
<script src="{:url('/')}ueditor/ueditor.all.min.js"></script>
<script src="{:url('/')}ueditor/lang/zh-cn/zh-cn.js"></script>