cURL / Mailing Lists / curl-users / Single Mail

curl-users

Problem with CURL script

From: EbersoleGrafxx <support_at_egrafxx.com>
Date: Wed, 8 Feb 2006 22:46:20 -0800

 

Could someone please confirm the following script? It is supposed to call a
PDF file for download.

<?php

if(!(isset($TestCookie)))

           {

                       header("location:download.php");

           }

if(trim($file_name) == "")

           {

                       header("location:files_details.php");

           }

$url = "http://www.sunbeltflooring.com/uploadfiles/$file_name";

#$url = "http://192.168.0.1:9000/Sunbelt/uploadfiles/$file_name";

header ("Content-Type:application/pdf");

$ch = curl_init();

curl_setopt($ch, CURLOPT_URL,$url);

curl_setopt($ch, CURLOPT_RETURNTRANSFER,1);

$result=curl_exec ($ch);

curl_close ($ch);

print $result;

?>

 

 

-----------------------------------------------------------

Glenda Ebersole

E Grafxx & Web Design

3333 Concours St., Suite 8108

Ontario, CA 91764

Office: 909-483-6909

 

Advertising Design Awards
Portfolio: www.egrafxx.com

 

-- 
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.375 / Virus Database: 267.15.2/252 - Release Date: 2/6/2006
 
  

image001.jpg
Received on 2006-02-09