doutuan4361 2018-08-09 16:41
浏览 248
已采纳

Ckeditor 5文件上传适配器错误

I'm using ckeditor classic 5, and i'm trying to upload images in it. I downloaded php lib Ckfinder3 php connector, set config.

When i'm trying to load image i have a massage: Cannot upload file *filename*.

Interesting moment, that they are fisically loaded on server: i can view it in directory, that set in my config file and this files are correct:

/var/www/projectfiles/downloadfiles/

The next step i'm check permission and groups: it's www-data 0777.

What can be a reason? Can you give some advice or solution?

Thanks!

UPD: init function

ClassicEditor
            .create( document.querySelector( '#material_preview' ), {
                ckfinder: {
                    uploadUrl: '/ckfinder/connector/?command=QuickUpload&type=Images'
                }

            } )
            .catch( error => {
                console.error( error );
            } );

php config:

$config['authentication'] = function () {
    return true;
};

$config['backends']['default'] = array(
    'name'         => 'default',
    'adapter'      => 'local',
    'baseUrl'      => 'http://files.project.com/downloadfiles/',
    'root'         => '/var/www/projectfiles/downloadfiles/',
    'chmodFiles'   => 0777,
    'chmodFolders' => 0777,
    'filesystemEncoding' => 'UTF-8'
);
  • 写回答

2条回答 默认 最新

  • dqn8235 2018-08-20 16:43
    关注

    Finally i got it!

    The connector path is valid. The problem was in cache folder's permisson in laravel. Be glad if it helps you.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 ads仿真结果在圆图上是怎么读数的
  • ¥20 Cotex M3的调试和程序执行方式是什么样的?
  • ¥20 java项目连接sqlserver时报ssl相关错误
  • ¥15 一道python难题3
  • ¥15 用matlab 设计一个不动点迭代法求解非线性方程组的代码
  • ¥15 牛顿斯科特系数表表示
  • ¥15 arduino 步进电机
  • ¥20 程序进入HardFault_Handler
  • ¥15 oracle集群安装出bug
  • ¥15 关于#python#的问题:自动化测试