You are here

function og_get_node_groups in Organic groups 5.7

Same name and namespace in other branches
  1. 5.8 og.module \og_get_node_groups()
  2. 5 og.module \og_get_node_groups()
  3. 5.2 og.module \og_get_node_groups()
  4. 5.3 og.module \og_get_node_groups()
  5. 6.2 og.module \og_get_node_groups()
  6. 6 og.module \og_get_node_groups()
1 call to og_get_node_groups()
og_nodeapi in ./og.module
Implementation of hook_nodeapi().

File

./og.module, line 1261

Code

function og_get_node_groups($node) {
  $groups = array();
  if (!og_is_group_type($node->type)) {
    $result = og_get_node_groups_result($node->nid);
    while ($row = db_fetch_object($result)) {
      $groups[$row->group_nid] = $row->title;
    }
    return $groups;
  }
}