Read lwpcook:
If the document you want to fetch is too large to be kept in memory, then 
you have two alternatives. You can instruct the library to write the 
document content to a file (second $ua->request() argument is a file name)

Go read that part.

>From: Rob McMillin <[EMAIL PROTECTED]>
>To: gil cohen <[EMAIL PROTECTED]>
>Subject: Re: How to write output of a GET request to disk?
>Date: Sun, 10 Sep 2000 01:12:27 -0700
>
>gil cohen wrote:
>
> > Okay here's some example code for the first part, but alas, I'm not too 
>sure
> > about the second:
> >
> >   use LWP::UserAgent;
> >   $ua = LWP::UserAgent->new;
> >   $ua->agent("$0/0.1 " . $ua->agent);
> >   # $ua->agent("Mozilla/8.0") # pretend we are very capable browser
> >   $file = "test.txt";
> >   $url = "http://www.slashdot.org";
> >   open OUTPUT, ">$file" or die ("Could not open $file for writing: 
>$!\n");
>
>Right... thanks. I think you don't understand that these files run into
>hundreds of megabytes. I do NOT want the data to be stored in memory, even 
>in
>an intermediate way. This was exactly what I was trying to avoid.
>
>
>--
>           http://www.pricegrabber.com | Dog is my co-pilot.
>
>

_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at 
http://profiles.msn.com.

Reply via email to