X-Git-Url: https://git.ao2.it/tweeper.git/blobdiff_plain/3f3df99b377eca4f2ed8870ff3f4559abd0bec80..ce298eb2050132bf1b30a811ec0e61803ffda6f6:/tweeper.php diff --git a/tweeper.php b/tweeper.php index bfc07f2..27be95d 100644 --- a/tweeper.php +++ b/tweeper.php @@ -32,7 +32,7 @@ date_default_timezone_set('UTC'); */ class Tweeper { - private static $USER_AGENT = "Mozilla/5.0 (Windows NT 6.1; rv:22.0) Gecko/20130405 Firefox/22.0"; + private static $userAgent = "Mozilla/5.0 (Windows NT 6.1; rv:22.0) Gecko/20130405 Firefox/22.0"; /** * Constructor sets up {@link $generate_enclosure}. @@ -77,7 +77,7 @@ class Tweeper { CURLOPT_SSL_VERIFYHOST => FALSE, CURLOPT_SSL_VERIFYPEER => FALSE, CURLOPT_HTTPHEADER => array('Accept-language: en'), - CURLOPT_USERAGENT => Tweeper::$USER_AGENT, + CURLOPT_USERAGENT => Tweeper::$userAgent, )); $contents = curl_exec($ch); curl_close($ch); @@ -98,7 +98,7 @@ class Tweeper { CURLOPT_RETURNTRANSFER => TRUE, CURLOPT_SSL_VERIFYHOST => FALSE, CURLOPT_SSL_VERIFYPEER => FALSE, - CURLOPT_USERAGENT => Tweeper::$USER_AGENT, + CURLOPT_USERAGENT => Tweeper::$userAgent, )); curl_exec($ch); $url_info = curl_getinfo($ch); @@ -213,7 +213,7 @@ class Tweeper { * Convert json to xml. */ private function json_to_xml($json, $root_node_name) { - // Apparenty the ObjectNormalizer used afterwards is not able to handle + // Apparently the ObjectNormalizer used afterwards is not able to handle // the stdClass object created by json_decode() with the default setting // $assoc = false; so use $assoc = true. $data = json_decode($json, $assoc = TRUE);