X-Git-Url: https://git.stricted.de/?p=GitHub%2FStricted%2Fspeedport-hybrid-php-api.git;a=blobdiff_plain;f=speedport.class.php;fp=speedport.class.php;h=fe2b8aebc6a70956273680a978d7187769728899;hp=d54dd2140f17b1c5feeac6b24e5d588f74a6a269;hb=a35e3e67ef4f11757bed8545bef5745b150da2ef;hpb=5e44cffa0fe42cb2bf5645490c3d1703b39e0303 diff --git a/speedport.class.php b/speedport.class.php index d54dd21..fe2b8ae 100644 --- a/speedport.class.php +++ b/speedport.class.php @@ -201,6 +201,24 @@ class speedport { return explode("\n", $data['body']); } + /** + * get the Missed Calls from router + * + * @return array + */ + public function getMissedCalls() { + $path = 'data/Syslog.json'; + $fields = array('exporttype' => '1'); + $cookie = 'challengev='.$this->challenge.'; '.$this->session; + $data = $this->sentRequest($path, $fields, $cookie); + + if (empty($data['body'])) { + throw new Exception('unable to get syslog data'); + } + + return explode("\n", $data['body']); + } + /** * sends the request to router *