Using the mirror() Function : LWP « Network « Perl






Using the mirror() Function

    


#!/usr/bin/perl -w

use LWP::Simple;
use strict;

my $url = "http://www.demo.org/";
my $file = "/tmp/demo";

my $status = mirror($url,$file);

die "Cannot retrieve $url" unless is_success($status);

   
    
    
    
  








Related examples in the same category

1.Using POST to post parameters to a Perl CGI