You are here

function hook_flag_access in Flag 7.2

Same name and namespace in other branches
  1. 6.2 flag.api.php \hook_flag_access()
  2. 7.3 flag.api.php \hook_flag_access()

Allow modules to allow or deny access to flagging.

Parameters

$flag: The flag object.

$content_id: The id of the entity in question.

$action: The action to test. Either 'flag' or 'unflag'.

$account: The user on whose behalf to test the flagging action.

Return value

Boolean TRUE if the user is allowed to flag/unflag the given content. FALSE otherwise.

See also

flag_flag:access()

1 function implements hook_flag_access()

Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.

flag_flag_access in ./flag.module
Implements hook_flag_access().
1 invocation of hook_flag_access()
flag_flag::access in ./flag.inc
Determines whether the user may flag, or unflag, the given content.

File

./flag.api.php, line 120
Hooks provided by the Flag module.

Code

function hook_flag_access($flag, $content_id, $action, $account) {
}