Re: Save page

From: Date: Mon, 10 May 2004 17:01:52 +0000
Subject: Re: Save page
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-185819@lists.php.net to get a copy of this message
* Thus wrote Curt Zirzow (php-general@zirzow.dyndns.org): > * Thus wrote Mike Mapsnac (mikerh9@hotmail.com): > > Hello > > > > I' m writing php script that will request page and save it locally. The > > page URL will be parameter (example: > > http://www.pagetoget.com/thispage.html). How php can > > request such page and > > save it locally on the file? > > $ch = curl_init(); > curl_setopt($ch, CURLOPT_FILE, '/path/to/output'); sorry that should be: $fp = fopen('/path/to/output', 'w'); curl_setopt($ch, CURLOPT_FILE, $fp ); Curt -- "I used to think I was indecisive, but now I'm not so sure."

« previous php.general (#185819) next »