You are here

function content_copy_groups in Content Construction Kit (CCK) 6

Same name and namespace in other branches
  1. 5 content_copy.module \content_copy_groups()

Get all the groups for a content type.

1 call to content_copy_groups()
content_copy_export_form in modules/content_copy/content_copy.module
A form to export field definitions.

File

modules/content_copy/content_copy.module, line 437
Adds capability to import/export CCK field data definitions.

Code

function content_copy_groups($type_name = '') {
  $groups = array();
  if (!$type_name || !module_exists('fieldgroup')) {
    return $groups;
  }
  $data = fieldgroup_groups($type_name);
  foreach ($data as $group_name => $group) {
    $groups[$group_name] = $group['label'] . ' (' . $group['group_name'] . ')';
  }
  return $groups;
}