ci框架引入css js 404

这几天正在学习ci框架,想使用bootstrap,但是发现并没有效果,network全是404,但是路径这些完全没有问题,于是怀疑是分布式配置文件的问题,先前隐藏index.php时随便复制的一段代码,RewriteEngine on
RewriteCond $1 !^(index\.php|images|js|img|css|robots\.txt)

RewriteRule ^(.*)$ index.php/$1 [L],加上两行过滤掉文件夹和文件即可载入css js文件:RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond $1 !^(index\.php|images|js|img|css|robots\.txt)
RewriteRule ^(.*)$ index.php/$1 [L]


猜你喜欢

转载自blog.csdn.net/aawuwuwuxx/article/details/79587732