Re: CURL

From: Date: Mon, 24 Sep 2001 21:31:37 +0000
Subject: Re: CURL
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-68607@lists.php.net to get a copy of this message
On Mon, 24 Sep 2001, Daniel Demacek wrote: > Hi, all > > anyone know how to get this to work? > > <?php > > # this is suppose to do same thing as fpassthru(); > # but using SSL > > > header("Content-Type: application/octet-stream"); > header("Content-Disposition: attachment; filename=" . $f); > > $ch = curl_init(); > $fp = fopen($the_path."/".$loginname.$f, "r"); > > curl_setopt ($ch, CURLOPT_INFILE, $fp); > curl_setopt ($ch, CURLOPT_INFILESIZE, $file_size); > > curl_setopt ($ch, CURLOPT_PUT, 1); > curl_setopt ($ch, CURLOPT_HEADER, 0); > > > curl_exec ($ch); > curl_close ($ch); > fclose ($fp); > ?> > What's the URL your fetching? You don't need SSL for file system access... -Sterling > > I have come to believe that the whole world is an enigma, a harmless enigma > that is made terrible by our own mad attempt to interpret it as though it > had an underlying truth. > > >

« previous php.general (#68607) next »