public static function SendinblueManager::getListNameById in SendinBlue 7
Same name and namespace in other branches
- 7.2 includes/sendinblue.manage.inc \SendinblueManager::getListNameById()
Get list name form id.
Parameters
int $list_id: A list id.
Return value
string A list name.
1 call to SendinblueManager::getListNameById()
- SendinBlueSignupUIController::overviewTable in includes/
sendinblue_signup.ui_controller.inc - Overrides parent::overviewTable().
File
- includes/
sendinblue.manage.inc, line 430 - Manage class file.
Class
- SendinblueManager
- Basic manager of module.
Code
public static function getListNameById($list_id) {
$access_key = variable_get(self::ACCESS_KEY, '');
$mailin = new SendinblueMailin(self::API_URL, $access_key);
$response = $mailin
->getList($list_id);
if ($response['code'] == 'success' && is_array($response['data'])) {
return $response['data']['name'];
}
return '';
}