listUpdate()

Update list parameters.

listUpdate(string $id, string $name, $value) : boolean
Input parametrs
  • id - list ID
  • name - name of parameter (see Creation of new list for possible parameter names)
  • value - value of parameter (see Creation of new list for possible parameter values)
Information obtained
  • true, if uppdate was successful. Otherwise, an error message is returned.

Examples

mgapi_listUpdate.php
listUpdate($id, $name, $value);
 
header("Content-Type: text/plain");
if ($api->errorCode){
    echo "Unable to load listUpdate()!\n";
    echo "\tCode=".$api->errorCode."\n";
    echo "\tMsg=".$api->errorMessage."\n";
} else {
    echo "SUCCESS! \n";
}
xml-rpc_listUpdate.php
 new xmlrpcval($apikey),
                    'id' => new xmlrpcval($listId),
                    'name' => new xmlrpcval('title'),
                    'value' => new xmlrpcval('New Title')
                ),
                'struct');
$f = new xmlrpcmsg('listUpdate', array($v));
$c = new xmlrpc_client($apiUrl["path"], $apiUrl['host'], 80);
$c->setDebug($debug);
$r = &$c->send($f);
 
header("Content-Type: text/plain");
if (!$r->faultCode()) {
    $retval = php_xmlrpc_decode($r->value());
    echo "Returned: " . $retval . "\n";
} else {
    echo "Unable to load listUpdate()!\n";
    echo "\tCode=" . $r->faultCode() . "\n";
    echo "\tMsg=" . $r->faultString() . "\n";
}

© 2010-2017 Mailigen. All rights reserved.