正则方式:
location / {
root html/xxxx/yyyy/;
index index.php index.html;
if ( !-e $request_filename ){
rewrite(.*) /index.php/$1;
}
}
/auth/login
index.php?/auth/login
try_files方式:
nginx.conf
location / {
root html/dddai/public/;
index index.php index.html;
try_files $uri /index.php?$uri;
}
版权声明:本文为taotaobaobei原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接和本声明。