I use whatever is fit for the job. If I want simplicity, I use LWP::Simple. If I need to fill out forms, I use WWW::Mechanize. If I need to connect to a busy server or through a flaky network and I need retries, I use wget. If I need something, and LWP isn't available, lynx might do the job as well. Or ftp, or ncftp. If it's being done using FTP, and I need to do something more fancy than retrieving a document, I use Net::FTP. If I want to recursively download something, or continue a partially downloaded file, I use wget. If I want to retrieve something, and display it immediately,
system "mozilla URL" might do the trick, or I use the remote control functionality of a running browser. If I need to be really fancy, I use LWP::UA. And for debugging, I might use "telnet host 80" from the command line.
I've used all of the methods I mentioned above. As with most programming techniques, it's a matter of finding the right trade-off between simplicity of the interface, your needs, your knowledge/experience of the tool, offered functionality and availability. It's a fallacy to think one tool is "better" than the other. A carpenter isn't going to say "I've a hammer and a screwdriver - why have both?" either.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.