New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sending request through sock5 proxy not working #1165
Comments
Which version of Guzzle are you using? |
I am using Goutte. And basically Goutte using Guzzle for scraping. Which version of Guzzle are you using?— |
I need to know specifically which version of Guzzle you are using. Maybe show me your composer.json or something. |
My composer.json shows "guzzlehttp/guzzle": ">=4,<6" I need to know specifically which version of Guzzle you are using. Maybe show me your composer.json or something.— |
More Info in this. I am getting this error when I try to overwrite the curl option using below code. $guzzle = $client->getClient(); Error I am getting Exception: cURL error 7: See http://curl.haxx.se/libcurl/c/libcurl-errors.html in [phar:///var/www/public_html/vendor/goutte/goutte.phar/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php, line 49] |
Yes, But same is working if I use curl directly to send my request without fail. ".CURLOPT_PROXYTYPE."<============>".CURLPROXY_SOCKS5."<=====>".CURLOPT_PROXY."<===="; //The URL to which to POST the data curl_setopt($ch, CURLOPT_URL, $url); //Execute $result = curl_exec($ch); curl_close($ch); // Closing cURL return $result; // Returning the data from the function}?>
To: guzzle/guzzle guzzle@noreply.github.com I see that this is curl-level error. |
I have did changes like below and now its working fine. :) $guzzle = $client->getClient(); thanks all for your help on this and also for nice library. |
👍 |
I am trying to send request through my local installed TOR proxy. It is working fine with my simple PHP CURL request with below two curl options setting. But through guzzle it is returning http status code 404 and also not got response properly.
$guzzle = new GuzzleClient(['base_url' => ['webtolife.com/ps.php', []],],
array('curl.options' => array(
'CURLOPT_PROXY' => $tor,
'CURLOPT_PROXYTYPE' => 'CURLPROXY_SOCKS5',
)
)
);
$client->setClient($guzzle);
Can someone please help me to solve this problem. I am trying to solve this since last 3 days but not able to solve.
The text was updated successfully, but these errors were encountered: