I need to add properties to a rendered field group, but I cannot find a way to do that. I would normally expect a preprocess function or a tpl to override the rendered output.

Thanks!
Sean

Comments

couloir007’s picture

OK, I found a way.

function module_field_group_pre_render(&$element, $group, & $form) {
	if($group->group_name == 'group_article_body') {
		$element['#prefix'] = '<div itemprop="articleBody" class="field-group-format ' . $group->group_name . ' ' . $group->classes . '">';
	}
}
nils.destoop’s picture

Status: Active » Closed (fixed)