I've found that using a proxy for http and https requests eliminates
this problem.  This is a good workaround for me, but it might suggest
that there's something LWP is missing in the way of handling socket
connections that other software (Apache, Lynx, Netscape...) does.

One other (somewhat unrelated) thing I found that might help someone
else out is that other browsers change the method of a redirected POST
to GET.  This was causing me problems where I couldn't get past the
login on a secure site - I kept getting redirected in a circle back to
the login page.

Here's some code that worked for me :

# User agent subclass to allow redirects on POSTs
@MyAgent::ISA = qw(LWP::UserAgent);
sub MyAgent::redirect_ok {
  my ($self,$request)=@_;
  if ($request->method eq "POST") {
    $request->method("GET");
  }
  return 1;
}

-- 
--------------------------------------------------------------
Fair Winds,     Software Engineer and WWW developer
Chris Dunn      MRM, inc.

Email: [EMAIL PROTECTED]
Phone: (919) 544-6500  Ext 228
Pager: (919) 506-0819

http://www4.ncsu.edu/~w_dunn
--------------------------------------------------------------

Reply via email to