in reply to LWP::UserAgent and no cookies in my response?

One thing I find useful when comparing the behavior of my browser to the behavior of a LWP::UserAgent object is to configure the object so that it mimics a real browser, because some servers will respond differently depending on the type of browser they think they are dealing with, and can be particularly unhelpful if they think they're dealing with a robot. (Yes: anti-mecha discrimination is rampant.) Try something like:

$ua->agent( 'Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.6) Gecko/2 +0050223 Firefox/1.0.1' );
See the agent parameter in the docs for LWP::UserAgent. (BTW, the code given above works as-is even if you are using LWP::Simple, as long as you import the package variable $ua from LWP::Simple.)

To determine what string to use, for Firefox I use the very handy Live HTTP headers.

the lowliest monk

Replies are listed 'Best First'.
Re^2: LWP::UserAgent and no cookies in my response?
by bageler (Hermit) on Jun 09, 2005 at 13:37 UTC
    yeah, been there done that. Still no worky. I'm up to forging the cookies now.