css和js文件没有加载多个.htaccess slimframework

时间:2016-11-22 16:16:21

标签: slim

我已经在public_html中直接设置了瘦骨架,在那个目录中它们是第一个.htaccess文件包含到公共文件夹的路由。 首先.htaccess包含:

RewriteEngine On

RewriteBase /public/
RewriteRule ^$ public/

由于我的域直接指向public / index.php 其中包含带有slimframework标准.htaccess文件的第二个.htaccess文件:

RewriteEngine On

# Some hosts may require you to use the `RewriteBase` directive.
# If you need to use the `RewriteBase` directive, it should be the
# absolute physical path to the directory that contains this htaccess file.
#
# RewriteBase /

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^ index.php [QSA,L]

因为这样我的css和js文件没有在模板中加载,它们就像在控制台中一样

  

获取http://domain.com/css/bootstrap.min.css   返回404错误   我从两天开始就遇到这个问题,但是仍然无法在我的本地服务器上工作正常但不能在godaddy服务器上工作。

0 个答案:

没有答案