根目录下.htaccess内容为:绑定到public目录下
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_URI} !^/public/
RewriteRule ^(.*)$ public/$1?Rewrite [L,QSA]
</IfModule>
如果需要指定域名
RewriteCond %{HTTP_HOST} ^www\.xxx\.com$ [NC]
根目录下.htaccess内容为:绑定到public目录下
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_URI} !^/public/
RewriteRule ^(.*)$ public/$1?Rewrite [L,QSA]
</IfModule>
如果需要指定域名
RewriteCond %{HTTP_HOST} ^www\.xxx\.com$ [NC]
本文标题:阿里云虚拟主机配置tp5项目,配置路由
本文链接:https://www.haomeiwen.com/subject/tgofdctx.html
网友评论