Commit e2954102 authored by Nguyễn Văn Ánh's avatar Nguyễn Văn Ánh

Revert "curl instead of file_get_contents"

parent 55d8c60f
...@@ -101,12 +101,7 @@ class NoCaptcha { ...@@ -101,12 +101,7 @@ class NoCaptcha {
{ {
$link = static::VERIFY_URL.'?'.http_build_query($query); $link = static::VERIFY_URL.'?'.http_build_query($query);
$curl = curl_init(); $response = file_get_contents($link);
curl_setopt($curl, CURLOPT_URL, $link);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curl, CURLOPT_TIMEOUT, 10);
$response = curl_exec($curl);
curl_close($curl);
return json_decode($response, true); return json_decode($response, true);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment