At 09:56 AM 2003-06-13 -0400, Alan Olegario wrote:
I've tried using the same type script against an http site, and still got the following response:

HTTP/1.1 405 Method Not Allowed

I bet that what's happening is this:
Your POST gets a redirection response. The HTTP spec says this should result in another POST, but, alas, "When automatically redirecting a POST request after receiving a 301 status code, some existing HTTP/1.0 user agents will erroneously change it into a GET request." So "many" (probably all) browsers do something else -- they do a GET in this circumstance, and that's what the programmers of the CGI you're posting to are assuming will happen. But since LWP does a POST instead, you get that error.


Gisle, haven't people filed patches for making LWP act like every other user-agent, instead of following the spec? If you don't have a patch for it, I could probably whip one up for you without too much bother.

--
Sean M. Burke    http://search.cpan.org/~sburke/



Reply via email to