function field_group_load_field_group in Field Group 7.2
Same name and namespace in other branches
- 8.3 field_group.module \field_group_load_field_group()
- 8 field_group.module \field_group_load_field_group()
- 7 field_group.module \field_group_load_field_group()
Loads a group definition.
Parameters
$group_name: The name of the group.
$entity_type: The name of the entity.
$bundle_name: The name of the bundle.
$mode: The view mode to load.
1 call to field_group_load_field_group()
- field_group_menu_load in ./
field_group.module - Menu Wildcard loader function to load group definitions.
File
- ./
field_group.module, line 125 - Fieldgroup module.
Code
function field_group_load_field_group($group_name, $entity_type, $bundle_name, $mode) {
ctools_include('export');
$objects = ctools_export_load_object('field_group', 'conditions', array(
'group_name' => $group_name,
'entity_type' => $entity_type,
'bundle' => $bundle_name,
'mode' => $mode,
));
$object = array_shift($objects);
if ($object && isset($object->data)) {
return field_group_unpack($object);
}
return $object;
}