in reply to Re^2: Can't call method "extract_cookies" on an undefined value
in thread Can't call method "extract_cookies" on an undefined value

When I look at the web page it downloads, I find

writeSessionCookie( 'oraclelicense', 'accept-securebackup-cookie' );

in it

Be nice if I could just add the cookie directly, like I can do with wget.

Replies are listed 'Best First'.
Re^4: Can't call method "extract_cookies" on an undefined value
by Todd Chester (Scribe) on Oct 17, 2015 at 06:23 UTC
    $ua = LWP::UserAgent->new; $ua->cookie_jar ($cookie_jar={}); # instead of $ua->cooki +e_jar ( +{} ); $request = HTTP::Request->new('GET', "$RevAddr" ); print "\$request = ", $request, "\n"; print Dumper ($request), "\n";

    $request = HTTP::Request=HASH(0x1080540) $VAR1 = bless( { '_content' => '', '_uri' => bless( do{\(my $o = 'http://www.ora +cle.com/ +technetwork/java/javase/downloads/jre7-downloads-1880261.html +')}, 'UR +I::http' ), '_headers' => bless( {}, 'HTTP::Headers' ), '_method' => 'GET' }, 'HTTP::Request' );

    What am I doing wrong?