Active
Project:
Addresses
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
22 Feb 2009 at 22:50 UTC
Updated:
22 Feb 2009 at 22:50 UTC
Hello,
At first I wanted to add an addresses subform in my form. After some time looking at the core , I was able to incorporate the addresses in my form with such code:
// Get the fields used on this address
$fields = variable_get('addresses_user', array());
$form['addresses'] = array(
'#default_value' => $values,
'#fields' => $fields,
'#uid' => $user->uid,
'#type' => 'addresses_elements',
'#tree' => TRUE
);
Now I woud like that this magic definition should be able to load the addresses of an user and update it when changes are made !
But I don't known how ?
Thank you in advance,
Michel