function multiple_email_message_part in Multiple E-mail Addresses 2.x
Same name and namespace in other branches
- 5 multiple_email.module \multiple_email_message_part()
- 6 multiple_email.module \multiple_email_message_part()
- 7 multiple_email.module \multiple_email_message_part()
Returns the part of the specified e-mail message based on site settings.
Parameters
string $part (subject or body):
string $type:
object $account:
object $email:
Return value
string
3 calls to multiple_email_message_part()
- multiple_email_expire_address in ./
multiple_email.module - Removes the specified address from the user who added it and sends their primary e-mail account a message notifying them about the expiration.
- multiple_email_send_confirmation in ./
multiple_email.module - Sends the confirmation e-mail for the specified address to the specified user account.
- UserTest::testMultipleEmailUser in src/
Tests/ UserTest.php - Test that the Multiple E-mails user can add a new e-mail address.
File
- ./
multiple_email.module, line 649 - multiple_email module file
Code
function multiple_email_message_part($part, $type, $account, $email) {
$func = "multiple_email_default_{$part}";
if (module_exists('i18n_variable')) {
$language = user_preferred_language($account);
$setting = i18n_variable_get("multiple_email_{$type}_{$part}", $language->language, $func($type));
}
else {
$setting = variable_get("multiple_email_{$type}_{$part}", $func($type));
}
return multiple_email_var_replace($setting, $account, $email);
}