Bernd Wurst commited on 2018-01-14 06:02:06
Zeige 2 geänderte Dateien mit 5 Einfügungen und 2 Löschungen.
| ... | ... |
@@ -171,9 +171,12 @@ class domainRobotApi {
|
| 171 | 171 |
|
| 172 | 172 |
private $transactionId = NULL; |
| 173 | 173 |
|
| 174 |
- public function __construct($authToken) |
|
| 174 |
+ public function __construct($authToken, $location = NULL) |
|
| 175 | 175 |
{
|
| 176 | 176 |
$this->authToken = $authToken; |
| 177 |
+ if ($location) {
|
|
| 178 |
+ $this->location = $location; |
|
| 179 |
+ } |
|
| 177 | 180 |
try {
|
| 178 | 181 |
if ($client = new SOAPClient(__DIR__."/domainrobot.wsdl", array('trace' => true, 'location' => $this->location, 'connection_timeout' => 10, 'features' => SOAP_SINGLE_ELEMENT_ARRAYS)))
|
| 179 | 182 |
{
|
| ... | ... |
@@ -38,7 +38,7 @@ function terions_available($domainname) |
| 38 | 38 |
if (! config('http.net-apikey')) {
|
| 39 | 39 |
system_failure("Kein API-Key vorhanden!");
|
| 40 | 40 |
} |
| 41 |
- $api = new domainRobotApi(config('http.net-apikey'));
|
|
| 41 |
+ $api = new domainRobotApi(config('http.net-apikey'), config('http.net-apiurl'));
|
|
| 42 | 42 |
$result = $api->domainStatus($domainname); |
| 43 | 43 |
if (isset($api->getValue()[0])) {
|
| 44 | 44 |
return ($api->getValue()[0]->status == 'available'); |
| 45 | 45 |