$reqSelect],'WSI2_AdressePointRelais.php');
$resConn=$idPdo->query($reqSelect);
if ($resConn) {
$res=$resConn->fetch(PDO::FETCH_ASSOC);
$MR_WebSiteId=$res['idCompte'];
$MR_WebSiteKey=$res['pwdCompte'];
if (isset($debug[2]) && $debug[2] == '1' ) {echo '
MR_WebSiteId= ' .$MR_WebSiteId;}
}
require_once ('nusoap-0.9.6/lib/nusoap.php');
$client = new nusoap_client("http://api.mondialrelay.com/Web_Services.asmx?WSDL", true);
$client->soap_defencoding = 'utf-8';
// param SOAP
$params = array(
'Enseigne' => $MR_WebSiteId,
'Num' => $_SESSION['idPointRelais'],
'Pays' => "Fr",
);
// On génère la clé de sécurité de l'appel
$code = implode("", $params);
$code .= $MR_WebSiteKey;
$params["Security"] = strtoupper(md5($code));
// l'appel SOAP
$result = $client->call(
'WSI2_AdressePointRelais',
$params,
'https://api.mondialrelay.com/',
'https://api.mondialrelay.com/WSI2_AdressePointRelais'
);
// On vérifie qu'il n'y a pas eu d'erreur
if ($client->fault) {
echo '
';
print_r($result);
echo '';
}else {
$err = $client->getError();
if ($err) {echo '' . $err . ''; } } if (isset($debug[1]) && $debug[1] == '1' ) $debugMsg .='
'.print_r($result). ''; if (isset($debug[1]) && $debug[1] == '1' ) echo '_SESSION[idPointRelais]=' .$_SESSION['idPointRelais']; $PRelais=$result; $myVar=""; // flag traduction EDT // $myVar='Liste des points relais'; $a=0; foreach($PRelais as $key => $value) { // $myVar= "\n
' . nl2br(htmlspecialchars($client->response, ENT_QUOTES)) . ''; if (isset($debug[1]) && $debug[1] == '1' ) $debugMsg .='
' . htmlspecialchars($client->getDebug(), ENT_QUOTES) . '