基本上我想要的是位于我的CSS文件:试图重写路径样式表
http://localhost/crm/Websites/crm/css/style.css
是accessable通过:
http://localhost/crm/css/style.css
我tryed一对夫妇的事情,但它不是工作,例如
RewriteRule ^/crm/css/style.css$ /crm/Websites/crm/css/style.css
RewriteRule ^(.+)/css/style.css$ $1/Websites/crm/css/style.css
有人能指出我做错了什么吗?
编辑:工作重写规则:
RewriteEngine On
RewriteCond %{REQUEST_URI} !=/favicon.ico
RewriteCond %{REQUEST_URI} !\.css$
RewriteRule ^(.*)$ index.php [PT,L]
尝试它,仍然给我404 ... :( –
请确保.htaccess位于根目录中,而不是在像“crm”的子文件夹中 – QQping
它位于文件夹crm。我使用xampp和我在htdocs文件夹中创建了一个名为crm的文件夹,并在那里创建了.htaccess ...它适用于其他事情(如将所有内容重写为index.php,rewritecond -f和-f等)所以我认为这是在正确的地方... –