Oara\Network\Publisher\Tyroo::checkConnection PHP Метод

checkConnection() публичный Метод

public checkConnection ( ) : mixed
Результат mixed
    public function checkConnection()
    {
        $postdata = \http_build_query(array('class' => 'Publisher', 'method' => 'getPublisher', 'val1' => $this->_sessionID, 'val2' => $this->_publisherID, 'val3' => ''));
        $opts = array('http' => array('method' => 'POST', 'header' => 'Content-type: application/x-www-form-urlencoded', 'content' => $postdata));
        $context = \stream_context_create($opts);
        $result = \unserialize(\file_get_contents('http://www.tyroocentral.com/www/api/v2/xmlrpc/APICall.php', false, $context));
        $connection = $result[0];
        return $connection;
    }