官方说的使用以下规则:
- <IfModule mod_rewrite.c>
- Options +FollowSymlinks -Multiviews
- RewriteEngine on
- RewriteCond %{REQUEST_FILENAME} !-d
- RewriteCond %{REQUEST_FILENAME} !-f
- RewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L]
- </IfModule>
必须在根目录(public)中的 “.htaccess”文件