简体   繁体   English

Internet Explorer 9 中 iframe 的 P3P 和 PHP session 问题

[英]P3P and PHP session problem with iframes in Internet Explorer 9

I have a contact form inside of an iframe, which uses captcha, and therefore requires session variables.我在 iframe 内部有一个联系表格,它使用验证码,因此需要 session 变量。 It works fine in every browser except IE9.它在除 IE9 之外的所有浏览器中都能正常工作。 To make it work in IE8, I added the following line at the beginning of the php document:为了让它在 IE8 中工作,我在 php 文档的开头添加了以下行:

header('P3P:CP="CAO IDC DSP COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"'); 

However, this doesn't appear to work in IE9.但是,这在 IE9 中似乎不起作用。 Any ideas?有任何想法吗?

Best Answer: @user973810最佳答案:@user973810

Thanks a lot.非常感谢。 This这个

header('P3P: CP="NOI ADM DEV PSAi NAV OUR STP IND DEM"');

helped me out very much.帮了我很大的忙。 It's questionable why only the IE does such strange things.值得怀疑的是为什么只有 IE 会做这些奇怪的事情。

Btw: here's the explanation for that.顺便说一句:这是对此的解释。 ;) ;)

  • NOI Web Site does not collected identified data. NOI Web 站点未收集已识别的数据。
  • ADM Information may be used for the technical support of the Web site and its computer system. ADM 信息可用于 Web 站点及其计算机系统的技术支持。 Users cannot opt-in or opt-out of this usage (same as tag ADMa).用户不能选择加入或退出这种使用(与标签 ADMa 相同)。
  • DEV Information may be used to enhance, evaluate, or otherwise review the site, service, product, or market. DEV 信息可用于增强、评估或以其他方式审查网站、服务、产品或市场。 Users cannot opt-in or opt-out of this usage (same as tag DEVa).用户不能选择加入或退出这种使用(与标签 DEVa 相同)。
  • PSAi Information may be used to create or build a record of a particular individual or computer that is tied to a pseudonymous identifier, without tying identified data (such as name, address, phone number, or email address) to the record. PSAi 信息可用于创建或建立与假名标识符相关的特定个人或计算机的记录,而无需将识别的数据(例如姓名、地址、电话号码或 email 地址)与记录绑定。 This profile will be used to determine the habits, interests, or other characteristics of individuals for purpose of research, analysis and reporting, but it will not be used to attempt to identify specific individuals.此个人资料将用于确定个人的习惯、兴趣或其他特征,以进行研究、分析和报告,但不会用于尝试识别特定个人。 Opt-in means prior consent must be provided by users.选择加入意味着必须由用户提供事先同意。
  • NAV Data passively generated by browsing the Web site -- such as which pages are visited, and how long users stay on each page. NAV 通过浏览 Web 站点被动生成的数据——例如访问了哪些页面,以及用户在每个页面上停留的时间。
  • OUR Ourselves and/or entities acting as our agents or entities for whom we are acting as an agent.我们自己和/或作为我们代理的实体或我们作为代理的实体。
  • STP Information is retained to meet the stated purpose.保留 STP 信息以满足所述目的。 This requires information to be discarded at the earliest time possible.这要求尽可能早地丢弃信息。 Sites MUST have a retention policy that establishes a destruction time table.站点必须具有建立销毁时间表的保留策略。 The retention policy MUST be included in or linked from the site's human-readable privacy policy.保留政策必须包含在网站的可读隐私政策中或与之链接。
  • IND Information is retained for an indeterminate period of time. IND 信息的保留时间不确定。 The absence of a retention policy would be reflected under this option.此选项下将反映没有保留政策。 Where the recipient is a public fora, this is the appropriate retention policy.如果收件人是公共论坛,这是适当的保留政策。
  • DEM Data about an individual's characteristics -- such as gender, age, and income. DEM 有关个人特征的数据——例如性别、年龄和收入。

Source: http://www.p3pwriter.com/lrn_111.asp来源: http://www.p3pwriter.com/lrn_111.asp

this one works for me IE to accept cross-browser cookies on all browsers这个适用于我IE 在所有浏览器上接受跨浏览器 cookies

add the following bit of code prior to any page output在任何页面之前添加以下代码位 output

header('p3p: CP="NOI ADM DEV PSAi COM NAV OUR OTR STP IND DEM"');

or this in the head block或者这个在头块中

<meta http-equiv="P3P" content='CP="NOI ADM DEV PSAi COM NAV OUR OTR STP IND DEM"' />

I've used this header and been able to save cookies in IE9:我已经使用了这个 header 并且能够在 IE9 中保存 cookies:

header('P3P: CP="NOI ADM DEV PSAi NAV OUR STP IND DEM"');

I've tried to find a resource for what all of these mean, but have never seen one.我试图找到所有这些含义的资源,但从未见过。 I do notice that there are some rules listed in my header that aren't in yours.我确实注意到我的 header 中列出的一些规则不在你的范围内。

I also host a p3p policy on the server, as outlined here: http://www.awardsites.com/tutorials/w3c/p3p_privacy-01.htm我还在服务器上托管了一个 p3p 策略,如下所述: http://www.awardsites.com/tutorials/w3c/p3p_privacy-01.htm

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM