PHP code example of aoding9 / dcat-tinymce-axupimgs

1. Go to this page and download the library: Download aoding9/dcat-tinymce-axupimgs 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/ */

    

aoding9 / dcat-tinymce-axupimgs example snippets



//...
'upload'=> [

        // Disk in `config/filesystem.php`.
        // 如果要上传oss,把disk改成qiniu或者别的驱动,然后配置好oss参数就行了
        'disk'      => 'admin',

        // Image and file upload path under the disk above.
        'directory' => [
            'image'        => 'images',
            'file'         => 'files',
            'image_editor' => 'images/editor/' . today()->toDateString(), // 全局修改多图上传目录
            'image_upload_url_editor' => null, // 全局修改多图上传接口
        ]


// ...
      $form->editor('content');
      
      // ->imageDirectory('custom_directory') 局部修改图片上传目录
      // ->imageUrl('custom_api_url') 局部修改图片上传接口