Options +FollowSymli
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L]
RewriteRule ^(.*)$ admin.php?/$1 [QSA,PT,L]
RewriteRule ^(.*)$ test.php?/$1 [QSA,PT,L]
</IfModule>
这样重写,貌似不行啊求大佬指点指点。已开启域名路由
想要的效果如下
入口文件index.php(绑定2个模块应用A下index模块,应用A下admin模块)
入口文件test.php (绑定应用B下index模块)
index.php绑定的是应用A下index模块, 域名为 test.com 和*.test.com
admin.php绑定的是应用A下admin模块, 域名为admin.test.com
test.php绑定的是应用B下index模块, 域名为test.test.com
Apache 配置
DocumentRoot "D:\myphp_www\PHPTutorial\WWW\test\public"
最佳答案