2009/10/13 Andrea Giammarchi <an_...@hotmail.com>:
>> > curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 0);
>> I wouldn't recommend setting this to 0 unless you're very sure that
>> the connection will succeed; otherwise, your script will hang
>> indefinitely waiting for the connection to be made.
> agreed, it's just he set timeout to zero so I guess he meant the curl
> connection as well otherwise it does not make sense to set the timeout to 0
> if curl has 10 seconds timeout :-)
> Regards

If he wants to download a very large file then it would make sense to
set_time_limit(0) but leave the curl connect timeout enabled; he
wouldn't want the PHP script timing out partway through a large
download. :) The curl timeout isn't for the transfer; just for making
the connection.



PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to