Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: Getting more out of LWP::Simple

by Juerd (Abbot)
on May 23, 2002 at 18:33 UTC ( #168867=note: print w/ replies, xml ) Need Help??


in reply to Getting more out of LWP::Simple

(No quotation available as I cannot copy/paste at the moment. Sorry)

While most people don't need POST, I do. IMHO, LWP::Simple needs a post function.

The namespace polution is awful, but with a few lines you can explicitly import some names the way you want them:

use LWP::Simple (); BEGIN { *lwp_get = \&LWP::Simple::get; *lwp_head = \&LWP::Simple::head; }
When LWP::Simple's functions are used only once or twice, just let it export nothing and use the full names including the package.

Thanks for the tutorial. I didn't know about the ability to export the underlying LWP::UserAgent object, but it will sure come in handy now I do.

- Yes, I reinvent wheels.
- Spam: Visit eurotraQ.


Comment on Re: Getting more out of LWP::Simple
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://168867]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (7)
As of 2014-11-29 02:42 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My preferred Perl binaries come from:














    Results (203 votes), past polls