function _mailchimp_get_user_tokens in Mailchimp 5
Same name and namespace in other branches
- 5.2 mailchimp.module \_mailchimp_get_user_tokens()
- 6.2 mailchimp.module \_mailchimp_get_user_tokens()
- 6 mailchimp.module \_mailchimp_get_user_tokens()
Get the user tokens for merging
1 call to _mailchimp_get_user_tokens()
- mailchimp_mailchimp_merge_values in ./
mailchimp.module - Implementation of hook_mailchimp_merge_values
File
- ./
mailchimp.module, line 629
Code
function _mailchimp_get_user_tokens($user) {
$out = array();
if (function_exists('token_get_values')) {
$vars = token_get_values('user', $user);
foreach ($vars->tokens as $key => $value) {
$out['token_' . $value] = $vars->values[$key];
}
}
return $out;
}