cURL / Mailing Lists / curl-and-php / Single Mail

curl-and-php

RE: cURL problem, nothing appear in the page

From: Cubic, Jason <Jason.Cubic_at_idt.com>
Date: Sun, 23 Dec 2007 13:01:38 -0800

try turning on verbose mode and viewing the error that is returned.
curl_setopt($ch, CURLOPT_VERBOSE, 1);

good luck.

-----Original Message-----
From: curl-and-php-bounces_at_cool.haxx.se on behalf of Douglas Fonseca
Sent: Sat 12/22/2007 7:50 PM
To: curl-and-php_at_cool.haxx.se
Subject: cURL problem, nothing appear in the page
 
Please, I need help!
I installed cURL library for php5 on my Ubuntu Linux. Everything looks OK.
When I open phpinfo() page the cURL is listed as installed and OK:
curl cURL support enabled cURL Information libcurl/7.15.5 OpenSSL/0.9.8c
zlib/1.2.3 libidn/0.6.5
But, when I do a page using cURL like:

<?php
$url = "http://www.google.com";
$ch = curl_init();
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_URL, $url);
$result = curl_exec($ch);
curl_close($ch);
echo $result;
?>

it does'nt work! When I open my Browser and try to apen the page, the page
opens, but with nothing in it!! Completely emply. No errors, no google page,
no contents. Nothing!
Please, with someone could help me, thank you!!

Merry Chistimas,
Douglas

_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php

Received on 2007-12-23