You know that cookies are kept on the client side, not the server side. Lamen's Terms (sp?): Cookie information is stored on the visitor's computer (visitor being the person looking at your site), not the computer that serves the web pages (where you do your work).
-----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: Monday, March 04, 2002 10:52 AM To: [EMAIL PROTECTED] Subject: Cookie question Hi, I have a javascript program that makes cookies from outside the cgi-bin. I want to access those cookies from a perl file within the cgi-bin. Cookies are a new subject to me and this is the code I've learned so far in making cookies. #!/usr/bin/perl -w # ic_cookies - sample CGI script that uses a cookie use CGI qw(:standard); use CGI::Cookie; use strict; my $cookname = "favorite ice cream"; my $favorite = param("flavor"); my $tasty = cookie($cookname) || 'mint'; unless ($favorite) { print header(), start_html("Ice Cookies"), h1("Hello Ice Cream"), hr(), start_form(), p("Please select a flavor: ", textfield("flavor",$tasty)),submit(), end_form(), hr(); exit; } my $cookie = cookie( -NAME => $cookname, -VALUE => $favorite, -EXPIRES => "+2nd", ); print header(-COOKIE => $cookie), start_html("Ice Cookies, #2"), h1("Hello Ice Cream"), p("You chose as your favorite flavor `$favorite'."); my%cookies = fetch CGI::Cookie; foreach (keys %cookies) { print "$cookies{$_}<br>"; } This code only picks up cookies from the directory it's called from. Should I add something to it? ---------------------------------------------------------------------------- -------------------- The views and opinions expressed in this email message are the sender's own, and do not necessarily represent the views and opinions of Summit Systems Inc. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]