默认配置文件是
if ($host = '123.com') {
rewrite ^/ https://456.com$request_uri permanent;
}
正常的链接都是成功的,但是比如程序是织梦里的TAG标签做跳转就出错了
比如原链接是https://123.com/tags.php?/nginx
301后直接就变成了https://456.com/tags.php?/nginx?/nginx
尾巴多了个重复参数,但是http下是正常的,https就多了个尾巴了
配置文件改成
if ($host = '123.com') {
rewrite ^(.*) https://456.com$1 permanent;
}
正常跳转