当有人访问时
http://127.0.0.1/something
我想将他重定向到
http://127.0.0.1/something/index.php
使用.htaccess。
提前致谢!
答案 0 :(得分:0)
我终于知道该怎么做了。
警告:我没有使用mod_rewrite的经验,所以这可能不是最佳解决方案。它适用于我。
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUESTFILENAME} !-f
RewriteRule ^(.*)/$ /$1/index.php [L]
</IfModule>