Re: LWP and Cookies
Kai Krebber (Kai.Krebber@sun.com)
Thu, 8 Mar 2001 08:50:28 +0000 (GMT)
Hi, Waseem!
I actually have the same effect. I tried out a sample program from a book
(Listing 19.5 from 'Perl 5 by Example'; e.g.
http://www.codebits.com/p5be/ch19.cfm on the server side) to avoid making a
conceptual mistake, but cookies still don't work in the client side, using LWP
(works with Netscape browser though).
I posted a request to this group on Feb 16th, but never got a response.
So if somebody would have a working sample using cookies with LWP::UserAgent
(and a http-proxy) that I could try out against an outside Webserver (sample URL
please too), I would appreceate it. I'm suspecting LWP-cookie handling not to
work at all (at least not on my SPARC Solaris).
Kai
> I am writing a perl script to track tranactions using
> a specific shopping cart, the problem is i using
> LWP::UserAgent to grab the pages and then grab the
> value of the cart before payment (this is a simple
> text processign thing)
>
> But if i use the normal site without (LWP) a cookie is
> set, for the shopping cart. But when i use LWP to goto
> the same page as the code shows below, no cookie is
> set thus no items enter the shopping cart .
>
> Thus i am using the HTTP:Cookies module thingy but all
> i get in the $cookie_jar is "#LWP-Cookies-1.0".