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).
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.
What am I missing?
Cookies are not shared between browsers. You'd have to rely on database/session id or tools such as this one:
http://www.ts0.com/crosscookie/example.html
Cheers
Try using server side cookies with few a!! May be it can be of some help
You can use session identifier and to store the cookie value on a server.
Application 1/Browser 1 - http://blabla/lele.php?cookieid=euueury576edhdhrtrtrt
Store the cookie info into SQL
Application 1/ Browser 2 - http://blabla/lele.php?cookieid=euueury576edhdhrtrtrt Here you can extract the cookie information from the server and set it on the new browser.
Using the similar scheme you can update the cookies between browsers also.
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 on Wikipedia
You can't set the cross browser cookies, cookies are set in the specific browser not at the server side.
One thing you can do is IP tracking, means you start storing the IP at your server, and the same call from different browser comes you set the cookie in that browser from server.