function flag_user::replace_tokens in Flag 5
Same name and namespace in other branches
- 6.2 flag.inc \flag_user::replace_tokens()
- 6 flag.inc \flag_user::replace_tokens()
File
- ./
flag.inc, line 1146 - Implements various flags. Uses object oriented style inspired by that of Views 2.
Class
- flag_user
- Implements a user flag.
Code
function replace_tokens($label, $contexts, $content_id) {
if ($content_id && ($user = $this
->fetch_content($content_id))) {
$contexts['user'] = $user;
}
return parent::replace_tokens($label, $contexts, $content_id);
}