Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

I'm trying to use LWP::Simple->getstore to retrieve an XML document from a remote server. I can access the document with a browser, but when I try getstore all I get is "501: Not Implemented." There's nothing fancy about the code:

$status = LWP::Simple->getstore ($harvest_url, $upload_loc); if (is_error ($status)) { $emsg = "***Upload failed on ->$harvest_url<-: "; $emsg .= "Code ->$status<- "; $emsg .= "Msg ->" . status_message ($status) . "<-"; Common::logmsg ($lsid, "$emsg"); die ("$lsid $emsg"); } else { Common::logmsg ($lsid, "on ->$args<- successful"); }

One of the SysAdmins thinks it has something to do with the fact that we're behind a "transparent" proxy, but he doesn't know for sure. This can't be that difficult. TIA for the advice.

Edited by planetscape - added code tags

Replies are listed 'Best First'.
Re: LWP::Simple->getstore Not Working
by japhy (Canon) on Mar 16, 2006 at 19:41 UTC
    'getstore' is not a method. LWP::Simple::getstore(...), not LWP::Simple->getstore(...).

    Jeff japhy Pinyan, P.L., P.M., P.O.D, X.S.: Perl, regex, and perl hacker
    How can we ever be the sold short or the cheated, we who for every service have long ago been overpaid? ~~ Meister Eckhart
    A reply falls below the community's threshold of quality. You may see it by logging in.