JellyBool

17773 经验值

恩,vuejs 2.0 应该不支持这个写法了

这个是因为 vuejs 的版本不一样吧。然后就是在 vuejs 2.0 的时候,

style="background:{ color }" // 这种写法已经去除了

嗯哼,你好,我看了一下源码:

https://github.com/overtrue/laravel-ueditor/blob/master/src/StorageManager.php#L217

代码貌似没有问题,不过可能是由于 rand() 这个函数在不同平台的表现不一样。比如 32 bit 的 windows 最大可能是 32767

http://php.net/manual/en/function.rand.php

所以目前来说,你改一下这一行代码,或者我去跟作者提个 pr 试试

 $randNum = mt_rand(1, 10000000000).mt_rand(1, 10000000000);
        if (preg_match("/\{mt_rand\:([\d]*)\}/i", $path, $matches)) {
            $path = preg_replace("/\{mt_rand\:[\d]*\}/i", substr($randNum, 0, $matches[1]), $path);
        }

没事,后面看视频的时候,推荐先看看评论

你确定一下 php_fileinfo 有没有开启呗。你可以在 chrome dev-tool 看到具体的错误的啊。

Failed to load resource: the server responded with a status of 500 (Internal Server Error)
ueditor.all.js:24515 POST http://localhost:8000/ueditor/server?action=upload-image&_token=DCOg4kfunug43Hgo0nhrvmraonGi8pTH8msKEBQ3 500 (Internal Server Error)
(anonymous) @ ueditor.all.js:24515
ueditor.all.js:24515 POST http://localhost:8000/ueditor/server?action=upload-image&_token=DCOg4kfunug43Hgo0nhrvmraonGi8pTH8msKEBQ3 500 (Internal Server Error)

这只是 console 的错误吧,你上传图片的时候看看 network 那里报错的 url ,再点开看具体的报错信息。

感觉是服务器的重写规则没有配置好,你用的是 apache 还是什么?

你看看 chrome dev-tool 有什么报错没?