Download & Extend

How to wrap address field output in fieldset?

Project:Addresses
Version:6.x-1.x-dev
Component:User interface
Category:support request
Priority:normal
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

Hello,

I was wondering how I could go about wrapping a fieldset around the output of addresses for a create/edit form?

I found that if I edit the function _addresses_addressesfieldapi_form in addresses.settings.inc and add an array like so

$form['address'] = array (
'#type' => 'fieldset',
'#title' => t('Address'),
'#collapsible' => TRUE,
'#collapsed' => FALSE,
);

and then add all the elements of address to the array that it would work, but I would rather not touch the modules files and instead override it from my template.php, I just don't know how..an example would be great.

Thanks

Comments

#1

You could do this by adding your field to a group.

#2

Status:active» closed (fixed)

aread22

Take a look at hook_form_alter() in the Drupal API. This will allow you to do what you wish.

nobody click here