//最近需要用到curl测试代理是否可用,代理是sock5非http的 所以需要在curl中增加几句。
curl_setopt($ch, CURLOPT_PROXYTYPE, CURLPROXY_SOCKS5);
curl_setopt($ch, CURLOPT_PROXY, "0.0.0.0:8080");
curl_setopt($ch,CURLOPT_PROXYUSERPWD, "username:pwd");
//测试ok 速度很快 哈哈
Statement:The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn