Dealing with HTTP Proxies via cURL
Today I needed to use curl, but this time via a http proxy that required authentication:
curl_setopt($ch, CURLOPT_HTTPPROXYTUNNEL, 1);
curl_setopt($ch, CURLOPT_PROXY, ‘proxy.mybusiness.null:8080′);
curl_setopt($ch, CURLOPT_PROXYUSERPWD, ‘user:password’);
Easy, huh? Just add those three lines before you call curl_exec().
Steven.