note 32044 added to ref.curl

From: Date: Wed, 14 May 2003 16:24:37 +0000
Subject: note 32044 added to ref.curl
Groups: php.notes 
Request: Send a blank email to php-notes+get-47969@lists.php.net to get a copy of this message
I've got the following simple request: <?php $ch = curl_init ("http://host/server-status"); curl_exec ($ch); curl_close ($ch); ?> But every time it took 15 sec. to fulfill the request. I checked every possible config and then I found the reason in httpd.conf: KeepAliveTimeout 15 But I didn't find an option to turn off keep-alive in cURL. So I used the following: curl_setopt ($ch, CURLOPT_HTTP_VERSION, CURL_HTTP_VERSION_1_0); Now it works fine in less than 1 sec. but is this the only solution??? To turn back to HTTP/1.0 ??? Best regards, greetings Johannes -- http://www.php.net/manual/en/ref.curl.php http://master.php.net/manage/user-notes.php?action=edit+32044 http://master.php.net/manage/user-notes.php?action=delete+32044 http://master.php.net/manage/user-notes.php?action=reject+32044

« previous php.notes (#47969) next »