jinyuansoftware / ckeditor
将 CKEDITOR 集成到 laravel-admin 中
dev-master
2024-03-22 12:55 UTC
Requires
- php: >=7.0.0
- encore/laravel-admin: *
Requires (Dev)
- phpunit/phpunit: ~6.0
This package is not auto-updated.
Last update: 2024-09-21 13:16:02 UTC
README
这是一个将 CKEDITOR
集成到 laravel-admin
表单的 laravel-admin
扩展。
截图
安装
composer require laravel-admin-ext/ckeditor
然后
php artisan vendor:publish --tag=laravel-admin-ckeditor
配置
在 config/admin.php
文件的 extensions
部分中,添加属于此扩展的配置。
'extensions' => [ 'ckeditor' => [ //Set to false if you want to disable this extension 'enable' => true, // Editor configuration 'config' => [ ] ] ]
编辑器的配置可以在 CKEditor 文档 中找到,例如配置语言和高度。
'config' => [ 'lang' => 'zh-CN', 'height' => 500, ]
用法
在表单中使用它
$form->ckeditor('content'); // Set config $form->ckeditor('content')->options(['lang' => 'fr', 'height' => 500]);
捐赠
通过捐赠一小笔钱来帮助项目开发继续进行。提前感谢。
许可
根据 MIT 许可证 (MIT) 许可。