如何从Yahoo或Gmail获取HTTP_REFERER [英] How to get the HTTP_REFERER from a Yahoo or Gmail

查看:116
本文介绍了如何从Yahoo或Gmail获取HTTP_REFERER的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个电子邮件脚本,该脚本将带有链接的邮件发送到Yahoo或Gmail,该链接将在单击时返回到我的网站.

I have an e-mailer script that send messages to Yahoo or Gmail with a link on it, a link that will return back to my website when it is clicked.

我需要从Yahoo或Gmail获取HTTP_REFERER.在我的网站上

I need to get the HTTP_REFERER from Yahoo or Gmail. in my site I have

echo $ _SERVER ["HTTP_REFERER"];

echo $_SERVER["HTTP_REFERER"];

期待一些回报.但它是空的.

expecting something to return on it. but its empty.

推荐答案

这似乎是设计使然.可以使用Javascript恶作剧删除标头.来自 Google关于GMail隐私的文档:

This seems to be by design. It is possible to remove the header using Javascript shenanigans. From Google's docs on GMail privacy:

最少的引荐来源"标头信息.当您单击消息中的链接时,加载的Web浏览器将包含引荐来源标头.当您单击Gmail中的链接时,Google会采取措施消除此引荐来源标头,以防止其他人知道您单击了电子邮件中的链接.

Minimized "referrer" header information. When you click on links in messages, the web browser that loads contains a referrer header. When you click on links in Gmail, Google takes steps to eliminate this referrer header, preventing others from knowing that you clicked on a link from an email.

这篇关于如何从Yahoo或Gmail获取HTTP_REFERER的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆