我有一些ht代码,我只想
知道这段代码到底做了什么?
RewriteCond %{HTTP_HOST} ^www\.(.+)$ [NC]
RewriteRule ^(.*)$ http://%1/$1 [R=301,L]
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_URI} !public
RewriteCond %{REQUEST_URI} !robots.txt
RewriteRule . /index.php [L]
</IfModule>
答案 0 :(得分:1)
www
/index.php
/public
和/robots.txt
以外的所有URI重写为/index.php