2017-04-25 61 views
0

Symfony2.8負荷資產形式的public_html /插件文件夾,但會拋出錯誤。負載Symfony的資產從的public_html/plugins文件夾

我的文件夾結構,

enter image description here

在我的主/生產服務器拋出錯誤, enter image description here

我不知道該怎麼辦,到解決這個錯誤...

我的配置文件..

enter image description here

PHP代碼用於資產,

<script src="{{asset('plugins/ckeditor/ckeditor.js')}}"></script> 
     {% if is_granted('IS_AUTHENTICATED_FULLY') %} 
      {% if is_granted('ROLE_FZ_ADMIN') %} 
       <script src="{{asset('plugins/ckeditor/config/fz.js')}}"></script> 
      {% elseif is_granted('ROLE_SUPER_ADMIN') %} 
       <script src="{{asset('plugins/ckeditor/config/super.js')}}"></script> 
      {% elseif is_granted('ROLE_ADMIN') %} 
       <script src="{{asset('plugins/ckeditor/config/admin.js')}}"></script> 
      {% else %} 
       <script src="{{asset('plugins/ckeditor/config/user.js')}}"></script> 
      {% endif %} 
     {% endif %} 
+0

你做了你的'assets:install'嗎?你有沒有自定義的'.htaccess'?您是否向我們展示了prod環境中的文件夾結構? – goto

+0

Thankyou,我刪除了.htaccess,然後在瀏覽器中沒有插件文件夾。然後更改文件夾權限。問題解決了。 –

回答

0

解決:此文件權限錯誤。將所有文件和文件夾更改爲777.問題解決。

chmod 777 -R project_location