dongzu3511 2018-08-27 13:53
浏览 325
已采纳

Laravel 5.7 - 使用命令'php artisan make:auth'后,Ckeditor停止显示

Before using the command

php artisan make:auth

the ckeditor, taken from the website https://github.com/UniSharp/laravel-ckeditor

was working fine.

After using the command, the ckeditor code has dissapeared in the file app.blade.php. In this case, the code

<script src="/vendor/unisharp/laravel-ckeditor/ckeditor.js"></script>
<script>
    CKEDITOR.replace( 'article-ckeditor' );
</script>

was put again in the app.blade.php and the following commands in the terminal were used once more:

composer require unisharp/laravel-ckeditor
php artisan vendor:publish --tag=ckeditor

Also,in the config/app.php in the addservice provider is still the:

Unisharp\Ckeditor\ServiceProvider::class,

I am doing tutorial from traversy media channel on the youtube, which link is the following laravel from scratch

My question is, what else I must write down in the Laravel, that the CKeditor will be visible.

  • 写回答

1条回答 默认 最新

  • dongshi1934 2018-10-10 18:11
    关注

    You done everything right, but after running this command

    php artisan make:auth
    

    The newly created app.blade.php contain "defer" in the line

    <script src="{{ asset('js/app.js') }}" defer></script>
    

    So remove the "defer", so it would be like

    <script src="{{ asset('js/app.js') }}"></script>
    

    and this will work.

    You can also move it to just before the </body> tag.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 求一个解密绿盾的代码或者程序,有偿!
  • ¥15 word样式右侧翻页键消失
  • ¥15 springboot+vue 集成keycloak sso到阿里云
  • ¥15 win7系统进入桌面过一秒后突然黑屏
  • ¥30 backtrader对于期货交易的现金和资产计算的问题
  • ¥15 求C# .net4.8小报表工具
  • ¥15 安装虚拟机时出现问题
  • ¥15 Selenium+docker Chrome不能运行
  • ¥15 mac电脑,安装charles后无法正常抓包
  • ¥18 visio打开文件一直显示文件未找到