Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: How do I use HTTP How do I use HTTP Cookies?

by Spidy (Chaplain)
on Aug 30, 2004 at 03:15 UTC ( [id://386831]=note: print w/replies, xml ) Need Help??


in reply to How do I use HTTP Cookies?

I still don't quite understand it....Could anyone give me an easy to understand example of writing a cookie, checking to see if a cookie exists, and deleting/clearing a cookie?

Thanks,
Spidy
  • Comment on Re: How do I use HTTP How do I use HTTP Cookies?

Replies are listed 'Best First'.
Re^2: How do I use HTTP Cookies?
by csuhockey3 (Curate) on Aug 30, 2004 at 03:29 UTC
    This might be better, as is it breaks down a working example. Do you have a good grasp of documentation and/or modules? As far a clearing the cookie, that is done by the expiration date. Have you tried anything on your own yet? If you have, we can help you more easily if you post some of your code that is giving you trouble.

    CSUhockey3
      I haven't tried anything with cookies yet, no. I want to start trying to do some cookie stuff, so I can actually have users stay logged in a bit more securely than including their username and password in an URL.
Re^2: How do I use HTTP Cookies?
by davido (Cardinal) on Aug 30, 2004 at 03:32 UTC

    You delete cookies by setting an expiration date that is a date prior to the date/time the cookie is being set. Or, set the cookie with no expiration date (in which case it will be deleted when the browser is closed).

    The rest of this that question was answered by the POD for CGI::Cookie, already pointed out in a previous followup. I see within that documentation, examples of creating cookies, retrieving cookies (which is the first step toward checking for the existance of one), and (through setting expiration date) dismissing them.


    Dave

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others admiring the Monastery: (5)
As of 2024-04-24 11:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found