[PHP] Re: cURL and Proxy Servers

2004-09-30 Thread Manuel Lemos
Hello,
On 09/30/2004 11:27 AM, Nick Wilson wrote:
I'm using cURL and have a question about this line (part of a function)
curl_setopt($ch, CURLOPT_PROXY, $proxy2use);
I know that *after* I curl_exec() i can find out if the proxy resolved
or not with curl_errno() (it would return 5) but it seems that if it
does fail to resolve, it will default to the users IP
This is not acceptable ;-)
I already check that the proxy is up and i can connect to it prior to
running my curl function, but if the proxy still doesnt resolve, how
might i prevent the curl function form executing?
You may want to try this HTTP client class instead. It supports requests 
via proxies and does not use Curl.

http://www.phpclasses.org/httpclient
--
Regards,
Manuel Lemos
PHP Classes - Free ready to use OOP components written in PHP
http://www.phpclasses.org/
PHP Reviews - Reviews of PHP books and other products
http://www.phpclasses.org/reviews/
Metastorage - Data object relational mapping layer generator
http://www.meta-language.net/metastorage.html
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Re: cURL and Proxy Servers

2004-09-30 Thread Nick Wilson

* and then Manuel Lemos declared
 You may want to try this HTTP client class instead. It supports requests 
 via proxies and does not use Curl.
 
 http://www.phpclasses.org/httpclient

Hmmm.. good point Manuel, i have seen the class, in fact it was the
original way i /was/ going to build the script. Wouldnt be hard to rip
out the cURL function and replace it with an http method, thanks...

-- 
Nick W

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