in reply to Re^3: Baking Cookies and Eating them
in thread Baking Cookies and Eating them
Data Dump
$VAR1 = { '{ username => barrycarlyon, password => 025a38ae929ace0637824f7728da371d }' => undef };
code:sub _cookie { #read in the lsrfm cookie to test my $self = shift; # my $cgi = CGI->new; # my $type = $cgi->param('type'); my $type = shift; #lets check to see if the lsrfm cookie exits #fecth the domains cookie my %cookies = fetch CGI::Cookie; my $cookies; my $lsrfm_cookie; if (!%cookies) { #a domain cookie doesnt exist #leave as blank } else { #a domain cookie exists #fetch the type value my $n = 0; my $this_cookie; my @cookies = (keys %cookies); foreach (keys %cookies) { $this_cookie = $cookies[$n]; if ($this_cookie eq ('LSRfm'.$type)) { $lsrfm_cookie = $cookies{'LSRfm'.$type}->value; } $n ++; } } use Data::Dumper; my %cookie_value = $cookies{'LSRfm'.$type}->value; print qq|<pre>|; print Dumper \%cookie_value; print qq|</pre>|; exit; return $lsrfm_cookie; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: Baking Cookies and Eating them
by stonecolddevin (Parson) on Sep 30, 2006 at 22:45 UTC | |
|
Re^5: Baking Cookies and Eating them
by grep (Monsignor) on Sep 30, 2006 at 22:15 UTC | |
by barrycarlyon (Beadle) on Sep 30, 2006 at 22:38 UTC |