我正在为电子邮件营销跟踪创建自己的电子邮件跟踪系统.我已经能够通过使用 http 引荐来源网址来确定他们正在使用的每个人的电子邮件客户端,但由于某种原因,GMAIL 根本不发送 HTTP_REFERRER!
I am creating my own email tracking system for email marketing tracking. I have been able to determine each persons email client they are using by using the http referrer but for some reason GMAIL does not send a HTTP_REFERRER at all!
所以我试图找到另一种方法来识别 gmail 何时从我的服务器请求透明图像.我得到以下标题 print_r($_SERVER);
:
So I am trying to find another way of identifying when gmail requests a transparent image from my server. I get the following headers print_r($_SERVER);
:
DOCUMENT_ROOT = /usr/local/apache/htdocs
GATEWAY_INTERFACE = CGI/1.1
HTTP_ACCEPT = */*
HTTP_ACCEPT_CHARSET = ISO-8859-1,utf-8;q=0.7,*;q=0.3
HTTP_ACCEPT_ENCODING = gzip,deflate,sdch
HTTP_ACCEPT_LANGUAGE = en-GB,en-US;q=0.8,en;q=0.6
HTTP_CONNECTION = keep-alive
HTTP_COOKIE = __utmz=156230011.1290976484.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); __utma=156230011.422791272.1290976484.1293034866.1293050468.7
HTTP_HOST = xx.xxx.xx.xxx
HTTP_USER_AGENT = Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.552.237 Safari/534.10
PATH = /bin:/usr/bin
QUERY_STRING = i=MTA=
REDIRECT_STATUS = 200
REMOTE_ADDR = xx.xxx.xx.xxx
REMOTE_PORT = 61296
REQUEST_METHOD = GET
该列表中有什么有用的吗?或者我还能做些什么来真正获得 http 引荐来源网址,如果不是其他 ESP 是如何设法找到是否使用 gmail 来查看电子邮件的?
Is there anything of use in that list? Or is there something else I can do to actually get the http referrer, if not how are other ESPs managing to find whether gmail was used to view an email?
顺便说一句,如果我们能阻止这是否合乎道德,我将不胜感激,因为许多 ESP 已经这样做了,我只是不想为他们的服务付费,我想在内部进行.
Btw, I appreciate it if we can hold back on whether this is ethical or not as many ESPs do this already, I just don't want to pay for their service and I want to do it internally.
感谢大家的任何实施建议.
Thanks all for any implementation advice.
只是想我会更新这个问题并根据赏金更清楚地说明.
Just thought I would update this question and make it clearer in light of the bounty.
我想知道用户何时打开我发送到 GMail 收件箱的电子邮件.假设,我有通常的透明图像跟踪,并且用户没有阻止图像.
I would like to find out when a user opens my email when sent to a GMail inbox. Assume, I have the usual transparent image tracking and the user does not block images.
我想使用单个请求和请求透明图像时获得的标头详细信息来执行此操作.
I would like to do this with the single request and the header details I get when the transparent image is requested.
你的图片是用 HTTP 还是 HTTPS 请求的?
Are your images requested with HTTP or HTTPS?
如果是这样,那就是问题所在.
If so, that's the problem.
HTTPS->HTTP 引荐不会泄露引荐标头 (HTTP_REFERER).
HTTPS->HTTP referrals do not leak a Referer Header (HTTP_REFERER).
如果您将 HTTP 托管图像嵌入到从 HTTPS 页面请求的电子邮件中,它不会发送引荐来源网址.(但是,请求 HTTPS 的 HTTP 页面确实会发送引用).解决方案是将图像嵌入为 HTTPS.我已经测试过了,果然,安全的 HTTPS 图像确实发送了 Referrer.
If you embed a HTTP hosted image in an email that is requested from an HTTPS page, it won't send a referrer. (HTTP pages requesting HTTPS, however, do send a referer).The solution is to embed the image as HTTPS. I've tested it, and sure enough, secure HTTPS images do indeed send the Referrer.
Gmail 可以在默认情况下阻止加载图像的引荐来源网址信息的一种方法是,如果他们使用 引荐来源网址政策,大多数现代浏览器都支持.(截至 2011 年,他们没有实施这样的政策.)
One way Gmail could block the referrer information on loaded images by default is if they used a referrer policy, which is supported on most modern browsers. (As of 2011, they did not implement such a policy.)
请参见下面的嵌入图像的屏幕截图,该图像是使用请求的 HTTP REFERER 动态生成的:
See the below screenshot of an embedded image that is generated dynamically with the HTTP REFERER of the request:
这篇关于电子邮件跟踪 - GMail的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!