Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

wget in Perl ?

by perlAffen (Sexton)
on Jan 26, 2006 at 16:10 UTC ( [id://525755]=perlquestion: print w/replies, xml ) Need Help??

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

I need wget for this AIX box I am working with. I has perl, but no complier. Actually I'll have to paste in via telnet any code I need....does anyone know of a wget util written in perl ? Thanks

Replies are listed 'Best First'.
Re: wget in Perl ?
by davorg (Chancellor) on Jan 26, 2006 at 16:30 UTC

    Does it need to be wget? Or can you get by with the GET program that is installed as part of LWP?

    --
    <http://dave.org.uk>

    "The first rule of Perl club is you do not talk about Perl club."
    -- Chip Salzenberg

    A reply falls below the community's threshold of quality. You may see it by logging in.
Re: wget in Perl ?
by EvanK (Chaplain) on Jan 26, 2006 at 16:27 UTC
    it would be fairly simple to write something like this with sockets, unless you're working with HUGE files.

    you could even URL-escape the entire file and use LWP::UserAgent to transfer them via http (i have seen it done before, though i certainly wouldnt recommend it in most cases).

    __________
    Build a man a fire, and he'll be warm for a day. Set a man on fire, and he'll be warm for the rest of his life.
    - Terry Pratchett

Re: wget in Perl ?
by glasswalk3r (Friar) on Jan 26, 2006 at 17:47 UTC

    You should check if PAR cannot help you getting the lwp-download (installed with the LWP distribuition) with a package and deploy it to the AIX. But probably your limited access to the AIX box won't let you do it.

    The Advanced Perl Programming book probably has a example or two using Sockets and IO::Sockets modules that you may use. You can try the Safary to have access to it. But you need to cross your fingers, because AIX is not particular updated when the subject is Perl and it's modules.

    Maybe downloading what you need in another box and having access to the file thru NFS is a better solution for you, after all.

    Alceu Rodrigues de Freitas Junior
    ---------------------------------
    "You have enemies? Good. That means you've stood up for something, sometime in your life." - Sir Winston Churchill
Re: wget in Perl ?
by brian_d_foy (Abbot) on Jan 26, 2006 at 18:32 UTC

    If you need WGET for the AIX box, does that mean that the AIX box can see the network? And, if you have Perl, do you have CPAN.pm, which can fetch and install modules and their dependencies?

    Are there some weird networking issues here? I would suspect some nasty firewall, but apparently you're using telnet.

    --
    brian d foy <brian@stonehenge.com>
    Subscribe to The Perl Review
      had to uuencode it and paste it in......UG !!!!!!!!!
Re: wget in Perl ?
by thor (Priest) on Jan 26, 2006 at 17:05 UTC
    You have to paste? You don't have ftp access to/from the box in question?

    thor

    The only easy day was yesterday

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://525755]
Approved by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chilling in the Monastery: (3)
As of 2024-04-26 08:17 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found