function flag_lists_get_flagged_content in Flag Lists 7
Same name and namespace in other branches
- 6 flag_lists.module \flag_lists_get_flagged_content()
- 7.3 flag_lists.module \flag_lists_get_flagged_content()
Get all flagged content in a flag.
Using this instead of flag_get_flagged_content() because we need to make sure that we use flag_lists_get_flags()
Parameters
The flag name for which to retrieve flagged content.:
1 call to flag_lists_get_flagged_content()
- theme_flag_lists_user_list in ./
flag_lists.module - Theme the output of user-defined list page
File
- ./
flag_lists.module, line 1175 - The Flag Lists module.
Code
function flag_lists_get_flagged_content($fid, $uid) {
$return = array();
$flag = flag_lists_get_flag($fid);
$result = db_select('flag_lists_content', 'f')
->fields('f')
->condition('f.fid', $flag->fid)
->condition('f.uid', $uid)
->execute();
foreach ($result as $row) {
$return[] = $row;
}
return $return;
}