Deduplicate and clean the recipient file
Clean the recipient file of a campaign (one that has not yet been sent).
array Nettoyer_Campagne( login, motdepasse, id_campagne)
Description
Remove duplicates and remove the addresses of unsubscribed contacts.
Parameters (required)
login: customer ID (nichandle)
motdepasse: the password
id_campagne: the campaign identifier
Return value
int: the number of recipients remaining after cleanup.
Error messages
No field must be left empty login
No field must be left empty motdepasse
This campaign does not appear to belong to you
This campaign has already been sent
Example with NuSOAP
The following example cleans the recipient file of a campaign:
include('nusoap/nusoap.php');
$client = new soapclient('https://www.eml-srv.com/_soap/control.php'); // Remove the 's' from https if CURL is not installed
$parametres = array( 'login'=>'your_login', 'motdepasse'=>'your_password', 'id_campagne'=>'id_campagne' );
$variable=$client->call('Nettoyer_Campagne', $parametres);
// Retrieve the error, if any
if($client->fault)
die("Error:Code: {$client->faultcode}"
. "Detail: {$client->faultactor}"
. "Solution: {$client->faultstring}");
echo $variable;Example with PHP5
try { $client = new SoapClient(null, array('location' => "https://www.eml-srv.com/_soap/control.php", 'uri' => "https://www.eml-srv.com", 'encoding'=>'ISO-8859-1' ));
$variable = $client->Nettoyer_Campagne('your_login','your_password','id_campagne'); //or //$variable = $client->__soapCall(Nettoyer_Campagne,$parametres);
//$variable=unserialize(rawurldecode($variable)); print_r($variable); } catch (SoapFault $fault) {
trigger_error("SOAP Fault: (faultcode: {$fault->faultcode}, faultstring: {$fault->faultstring})", E_USER_ERROR);
}Last updated on