You are here

function fieldgroup_get_group in Content Construction Kit (CCK) 6

Same name and namespace in other branches
  1. 5 fieldgroup.module \fieldgroup_get_group()
  2. 6.3 modules/fieldgroup/fieldgroup.module \fieldgroup_get_group()
  3. 6.2 modules/fieldgroup/fieldgroup.module \fieldgroup_get_group()

File

modules/fieldgroup/fieldgroup.module, line 511
Create field groups for CCK fields.

Code

function fieldgroup_get_group($content_type, $field_name) {
  foreach (fieldgroup_groups($content_type) as $group_name => $group) {
    if (in_array($field_name, array_keys($group['fields']))) {
      return $group_name;
    }
  }
  return FALSE;
}