Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re: Help With First LWP Script

by tomhukins (Curate)
on Jul 12, 2004 at 17:36 UTC ( #373669=note: print w/replies, xml ) Need Help??


in reply to Help With First LWP Script

Other responses should help you solve your problem, but I hope you don't mind me pointing out a couple of minor style issues with your code:

You use LWP::Simple yet never do anything with this class. If you don't call any methods on a class, you don't need to include it in your program.

You create an LWP::UserAgent object using an indirect method call (new LWP::UserAgent as opposed to LWP::UserAgent->new()) which will cause problems if you have a new() subroutine in your current package. In general, it's best to avoid indirect method calls.

Replies are listed 'Best First'.
Re^2: Help With First LWP Script
by Dru (Hermit) on Jul 12, 2004 at 17:51 UTC
    Thanks Mercio, that helped me to get it working and thanks to you, tomhukins, I cleaned up my script with your recommendations.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (5)
As of 2021-01-23 20:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Notices?