I was wondering how you target a field group with form_set_error, so the error border is correctly applied. using form_set_error('#groups][group_name',t('error')); or form_set_error('#fieldgroups][group_name',t('error')); did not work.


zuuperman’s picture

This is currently not possible, because the groups are objects. They are changed to the correct form element at rendering time

Hydra’s picture

Status: Active » Postponed

We should take care about this on a later version, thanks for reporting!

akhodakovskiy’s picture

Can you please tell if this development is anyhow previewed? One of my projects is hardly missing this functionality.
Is it possible to report an error with a definition of the group, where the field with error is situated, like 'group_name.field_name'?