http -> https
This commit is contained in:
parent
5c421805bf
commit
86b40f338c
3 changed files with 11 additions and 6 deletions
|
|
@ -97,15 +97,20 @@ class Connection_HttpRequest
|
|||
}
|
||||
|
||||
static function getJSON($url, $data) {
|
||||
$c = new Connection_HttpRequest();
|
||||
$query = http_build_query($data);
|
||||
$q = $url . '?' . $query;
|
||||
/*$c = new Connection_HttpRequest();
|
||||
$c->http_version = "HTTP/1.0";
|
||||
|
||||
$query = http_build_query($data);
|
||||
$c->setUrl($q = $url . '?' . $query);
|
||||
|
||||
$c->setUrl($q);
|
||||
$page = $c->getPage();
|
||||
|
||||
$response = new Connection_HttpResponse($page);
|
||||
return json_decode((string) preg_replace('/[\x00-\x09\x0B\x0C\x0E-\x1F\x7F]/', '', $response->getData()), true);
|
||||
$data = $response->getData();
|
||||
*/
|
||||
$data = file_get_contents($q);
|
||||
return json_decode((string) preg_replace('/[\x00-\x09\x0B\x0C\x0E-\x1F\x7F]/', '', $data), true);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue