我遇到了重写URL的问题。 下面发生的事情:.htaccess文件重写
http://www.mysite.nl/scores http://www.mysite.nl/registreren http://www.mysite.nl/login
这些URL将被重定向到index.php路线=分数等
这是所有工作得很好?但是现在我已经在像图像和样式表这样的子目录中获得了模板文件。这些文件是在
- 模板/ CSS/style.css中
- 图像/ images.png等
现在所有这些文件也beeïng重定向到的index.php?路径。
我知道前导斜杠和文件的所有链接都是绝对路径。
以下代码是在.htaccess文件中使用的beeïng。
RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^(.*)/?$ index.php?route=$1 [L,QSA]
要测试评论你的RewriteRule上面,然后尝试点击:[你的CSS](http://www.bitterballenscore.nl/template/style.css) – anubhava 2012-04-11 13:14:13