Beefy Boxes and Bandwidth Generously Provided by pair Networks Bob
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: Get Cookies for Form Input

by Anonymous Monk
on Sep 16, 2010 at 03:44 UTC ( #860310=note: print w/ replies, xml ) Need Help??


in reply to Get Cookies for Form Input

I'm sorry, it seems that my first message was a bit confusing. To clarify:

The first application is a PHP/PERL combination with cookies that comes from the PERL code. The second application is all PERL.

I want to get the data from the cookies and pass it to second application.


Comment on Re: Get Cookies for Form Input
Re^2: Get Cookies for Form Input
by superfrink (Curate) on Sep 16, 2010 at 19:22 UTC
    Depending on the domain names in the applications' URLs the second application may be able to read the contents of the cookie set by the first application.

    If the first application runs at http://nonprofit.org/a/ and the second application runs at http://nonprofit.org/b/ then the second application will get the cookie data because the browser will send it via HTTP headers.

    If the applications are on different subdomains like a.nonprofit.org and b.nonprofit.org then you may have to update the code that creates the cookie to specify the cookie's domain be nonprofit.org. That will tell the browser to send the cookie data to both applications. Of course then c.nonprofit.org will also get sent a copy of the cookie data when the browser visits it and that may not be desirable for privacy reasons.

    Update: ++Your Mother is right about the path. For some more cookie information visit http://www.cookiecentral.com/faq/#3.2
      Thanks for information.

      Everything is coming and going from the same domain, only different sub-directories. The sessions are timed and clicking 'logout' will overwrite the cookies.

      This is not necessarily true. If the cookies contain path constraints and they differ, they will not be available to anything on different paths. And I'm not positive, been a long time since I had to do it, but I believe you have to set the domain to .nonprofit.org (leading dot) to make it available to subdomains.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://860310]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (6)
As of 2014-04-20 09:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (485 votes), past polls