referer的情况

能获取到referer的情况:
1. 使用A标签来访问页面
2. submit input提交的表单post和get
3. 使用js提交的post和get表单

不能获取的referer的情况:
1. 使用js重定向 location.href 和 location.replace()
2. 服务器端的redirect,PHP中的header(“location:”)
3. 使用http重定向(我开始做的就是http重定向的项目,所以得不到referer参数)

猜你喜欢

转载自blog.csdn.net/pansuyong/article/details/81414397