commit | author | age
|
413d3b
|
1 |
<?php |
T |
2 |
|
b1a6a5
|
3 |
require 'soap_config.php'; |
413d3b
|
4 |
|
T |
5 |
|
|
6 |
$client = new SoapClient(null, array('location' => $soap_location, |
b1a6a5
|
7 |
'uri' => $soap_uri, |
MC |
8 |
'trace' => 1, |
|
9 |
'exceptions' => 1)); |
413d3b
|
10 |
|
T |
11 |
|
|
12 |
try { |
b1a6a5
|
13 |
if($session_id = $client->login($username, $password)) { |
413d3b
|
14 |
echo 'Logged successfull. Session ID:'.$session_id.'<br />'; |
T |
15 |
} |
b1a6a5
|
16 |
|
413d3b
|
17 |
//* Set the function parameters. |
T |
18 |
$status = 'active'; |
|
19 |
$primary_id = 1; |
b1a6a5
|
20 |
|
413d3b
|
21 |
$record_record = $client->sites_web_domain_set_status($session_id, $primary_id, $status); |
T |
22 |
|
|
23 |
print_r($record_record); |
|
24 |
echo "<br>"; |
b1a6a5
|
25 |
|
413d3b
|
26 |
if($client->logout($session_id)) { |
T |
27 |
echo 'Logged out.<br />'; |
|
28 |
} |
b1a6a5
|
29 |
|
MC |
30 |
|
413d3b
|
31 |
} catch (SoapFault $e) { |
T |
32 |
echo $client->__getLastResponse(); |
|
33 |
die('SOAP Error: '.$e->getMessage()); |
|
34 |
} |
|
35 |
|
|
36 |
?> |