如果在< iframe>中点击链接,HTTP Referer是什么? [英] What is the HTTP Referer if the link is clicked in an <iframe>?
问题描述
假设我有一个网页位于 http://www.website.com ,并带有< iframe> ;
在里面。像这样:
< html>
< head> ...< / head>
< body>
...
< iframe src =http://www.washington.edu>
...
< / body>
< / html>
现在假设有人前往www.website.com并单击iframe中的链接(此链接位于www.washington.edu网站)。
我的问题是这种情况下的HTTP Referer是什么?
它是 http://www.website.com (托管iframe的页面)还是http://www.washington.edu (链接被点击的页面)?
它取决于浏览器。
Firefox和Safari会将引用链接报告为,而某些版本的Internet Explorer将显示 http://www.washington.edu 作为推荐人。
更新2015-04:测试上述最新版本,所有人都会返回 http://www.washington.edu
Suppose I have a webpage located at http://www.website.com with an <iframe>
in it. Like this:
<html>
<head>...</head>
<body>
...
<iframe src="http://www.washington.edu">
...
</body>
</html>
Now suppose someone goes to www.website.com and clicks a link in the iframe itself (this link is located on www.washington.edu website).
My question is what is the HTTP Referer in this case?
Is it http://www.website.com (the page hosting iframe) or is it http://www.washington.edu (the page in which the link was clicked)?
It depends on the browser.
Firefox and Safari will report the referrer as http://www.website.com while some versions of Internet Explorer will show http://www.washington.edu as the referrer.
UPDATE 2015-04: Testing latest versions of above mentioned, all of them would return http://www.washington.edu
这篇关于如果在< iframe>中点击链接,HTTP Referer是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!