首页
mac
it
登录
6mi
u
盘
搜
搜 索
it
yii2 生产环境https跳转301 302无效。
yii2 生产环境https跳转301 302无效。
mac
2024-05-09
34
生产环境用的https:// 导致功能间跳转有问题。
原先用的是
header("Location: {$url}");
或者Yii自带的。
return Yii::$app->response->redirect($url);
改用原始的。
echo "<script>location.href=$url;</script>";
就可以不报302.正常跳转了。
原理很简单,加载层次不同。
转载请注明原文地址: https://mac.8miu.com/read-490694.html
最新回复
(
0
)