aquitaine has asked for the wisdom of the Perl Monks concerning the following question:
http://www.cnn.com/ http://www.bbc.com/ http://www.news.com/i would like to use LWP::Simple;
I dont know the real code i want for this, could someone help me out please ?#!/usr/bin/perl -w use LWP::Simple; use strict; my @urls = qw!http://www.cnn.com/ http://www.bbc.com/ http://www.news.com/!; for (@urls) { &get_em($_); } sub get_em { my $url = shift; $url =~ m!http://www.(.*?)/!; if ($pid = fork) { } elsif ($pid == 0 ) { getstore($url, "$1.txt"); } }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: fork subroutine
by saintmike (Vicar) on Apr 12, 2004 at 20:48 UTC | |
Re: fork subroutine
by jweed (Chaplain) on Apr 12, 2004 at 20:39 UTC | |
by tilly (Archbishop) on Apr 13, 2004 at 01:43 UTC | |
Re: fork subroutine
by gmpassos (Priest) on Apr 13, 2004 at 06:59 UTC | |
Re: fork subroutine
by DigitalKitty (Parson) on Apr 13, 2004 at 10:11 UTC |