Andy_que 发表于 2011-1-25 22:19:04

关于url中去掉index.php之后模板文件中的样式显示不来

我是CI新手
问题是这样的
我在URL中去掉index.php

.htaccess文件中写
RewriteEngine on
RewriteCond $1 !^(index\.php|images|robots\.txt)
RewriteRule ^(.*)$ /CodeIgniter/index.php/$1

views中的模板文件
<link rel="stylesheet" type="text/css"href="<?php echo base_url();?>system/application/views/css/style.css" />
这个样式显示不出来
假如不去掉url中的index.php就能显示这个样式出来

是什么原因?

Hex 发表于 2011-1-26 11:00:28

css images 必须放到 index.php 所在目录,
system 目录下不允许放任何非 PHP 文件。
这个已经强调很多次了。
页: [1]
查看完整版本: 关于url中去掉index.php之后模板文件中的样式显示不来