in reply to Redirection in LWP with POST

Hi,

LWP::Useragent doesn't automatically follow a redirect as an answer to a POST. So you need to change the default setting.

Change the default setting applies to LWP::Useragent, your script, NOT the server. LWP::Useragent is your browser. So a 302 reply from the server makes your browser point to the new destination. Without the change in default setting LWP:Useragent wouldn't reflect this change.

--
if ( 1 ) { $postman->ring() for (1..2); }

Replies are listed 'Best First'.
Re^2: Redirection in LWP with POST
by Anonymous Monk on Sep 26, 2005 at 11:04 UTC
    Hi,
    Actually, the response I got through POST is a page that should redirect itself to give a final page after the server finished its calculation. The calculation takes time to do it.

    I changed the default setting in my script, but I couldn't get the final page.

    Does the redirection 'consider' the resquest finished because the server 'looks' idle for a while during calculation and then terminate the resquest?
    I'm not sure the problems I got, just make a guess.

    thx