You are here

function _flag_get_flag_names in Flag 6.2

Same name and namespace in other branches
  1. 5 flag.module \_flag_get_flag_names()
  2. 6 flag.module \_flag_get_flag_names()
  3. 7.3 flag.module \_flag_get_flag_names()
  4. 7.2 flag.module \_flag_get_flag_names()

Return an array of flag names keyed by fid.

2 calls to _flag_get_flag_names()
flag_get_content_flags in ./flag.module
Return a list of users who have flagged a piece of content.
flag_get_user_flags in ./flag.module
Find what a user has flagged, either a single node or on the entire site.

File

./flag.module, line 1168
The Flag module.

Code

function _flag_get_flag_names() {
  $flags = flag_get_flags();
  $flag_names = array();
  foreach ($flags as $flag) {
    $flag_names[$flag->fid] = $flag->name;
  }
  return $flag_names;
}