示例#1
0
文件: Helper.php 项目: bashkarev/r01
 /**
  * generate nic_hdl
  * @param $id
  * @param bool $org
  * @return mixed|string
  */
 public static function hdl($id, $org = false)
 {
     $r = Connection::get()->hdl;
     $r .= '_' . $id . '_';
     $r .= mb_substr(md5($id), 0, 8);
     $r .= $org ? '-ORG-R01' : '-R01';
     return mb_strtoupper($r, 'UTF-8');
 }
示例#2
0
文件: Api.php 项目: bashkarev/r01
 /**
  * @return Connection
  */
 public function getClient()
 {
     return Connection::get();
 }
示例#3
0
<?php

require_once __DIR__ . '/../vendor/autoload.php';
use bashkarev\r01\soap\Connection;
Connection::set(new Connection(['login' => 'testreseller', 'password' => 'testreseller', 'hdl' => 'TEST', 'debug' => true, 'options' => ['location' => '	https://partner.r01.ru:1443/partner_api.khtml', 'uri' => 'urn:RegbaseSoapInterface', 'exceptions' => true, 'user_agent' => 'RegbaseSoapInterfaceClient', 'trace' => 1]]));
示例#4
0
 public function testLogOut()
 {
     $this->client->logOut();
     $this->assertTrue(!isset($this->client->soap->_cookies['SOAPClient']));
 }