httpd-apreq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Philip M. Gollucci" <>
Subject Re: Apache2::Cookies - getting all names
Date Tue, 03 Jan 2006 01:17:57 GMT
 >Joe Sschaefer wrote:
 >-1.  We need to fix cookies(), not fetch().  Patch cookies()
 >so it actually works as documented.

If I'm reading the docs for Apache2::Cookie::Jar correctly, we don't 
have function that will get alls cookies as an array we just have these 

     $cookie = $j->cookies("foo");  # first foo cookie
     @cookies = $j->cookies("foo"); # all foo cookies
     @names = $j->cookies();        # all cookie names

If you add in Apache2::Cookie->fetch()

     my $cookies = Apache2::Cookie->fetch($r); #
     my %cookies = Apache2::Cookie->fetch($r);

Whats missing from that is

@cookies = $j->cookies() # all COOKIES (PERIOD)

which is really what I wish $j->cookies() would do instead of names.

I sort of agree with Jeff in that we should add

@names = $j->cookie_names() # all cookie names

in conjunction with the above.

I agree with not changing fetch().

And in fact, fetch would break down if you have multiple cookies of the 
same name?


"Love is not the one you can picture yourself marrying,
but the one you can't picture the rest of your life without."

"It takes a minute to have a crush on someone, an hour to like someone,
and a day to love someone, but it takes a lifetime to forget someone..."

Philip M. Gollucci ( 301.254.5198
Consultant /
Senior Software Engineer - TicketMaster -

View raw message