首先必须保证apache开启路由重写功能;
然后新建一个.htaccess文件
内容为:
<ifmodule mod_rewrite.c>
RewriteEngine on
#RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L]
</ifmodule>
首先必须保证apache开启路由重写功能;
然后新建一个.htaccess文件
内容为:
<ifmodule mod_rewrite.c>
RewriteEngine on
#RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L]
</ifmodule>
转载于:https://www.cnblogs.com/woshiyinmo/p/3380564.html