跨浏览器cookie在php。在不同浏览器之间传递Cookie [英] Cross browser cookie in php. Pass cookies between different browsers

查看:599
本文介绍了跨浏览器cookie在php。在不同浏览器之间传递Cookie的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了一个应用程序,我试图将一个cookie从一个应用程序传递到另一个应用程序,工作在两个不同的端口在apache。 (像application1在80和Application2在8080)。

I have created an application and I am trying to pass a cookie from one to another application that works in two different ports in apache. (Like application1 in 80 and Application2 in 8080).

这很好,但是,当我在不同的浏览器打开同一个应用程序时,Cookie不显示在Application2 。只有当我在同一个浏览器中打开应用程序时,它才是好的。

That works fine but, when I open the same application in different browsers, the cookie is not being shown in the Application2. Only when I open the application in same browser it is fine.

我缺少什么?

推荐答案

Cookie是从网络服务器发送到浏览器的HTTP头。浏览器然后基于为该cookie定义的参数将所述报头的内容存储在磁盘或存储器上。 Cookie不在浏览器之间共享。

A cookie is a HTTP header sent from the webserver to the browser. The browser then stores the contents of said header on disk or memory, based on the parameters defined for this cookie. Cookies are not shared between browsers.

维基百科上的HTTP Cookie

这篇关于跨浏览器cookie在php。在不同浏览器之间传递Cookie的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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