PHP code example of banbans / laravel-ckeditor
1. Go to this page and download the library: Download banbans/laravel-ckeditor library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
banbans / laravel-ckeditor example snippets
Banbans\Ckeditor\EditorServiceProvider::class
'Ckeditor' =>Banbans\Ckeditor\Ckeditor::class,
php artisan vendor:publish --provider="Banbans\Ckeditor\EditorServiceProvider" --tag="ckeditor"
//调用编辑器
{{ Ckeditor::content('内容', ['id'=>'editor', 'class'=>'text-editor']) }}
//调用JS 多次调用编辑器可以多次调用js,传入id就可以
{{ Ckeditor::js('editor') }}