Storing User preferences in Drupal I recently developed a module where I used the function hook_form_user_profile_form_alter(&amp;$form, &amp;$form_state) to capture user preferences and saved them using function hook_user_presave(&amp;$edit, $account, $category) .
Then I accessed the data using $user->data['field']  in a module . That worked fine .    

But now  I want to store the same preferences using another form (not the user profile form).
So is there any other hook to store them ? 

I want to give a link to each user to the page(form other than the user profile ) where he can store his preferences .

Thanks in advance.
You don't need to use a hook you need to use the API function user_save(). Which is a very weird function because unlike all other save functions, it has a separate argument for the things that you want to change.

Something like this should work, in your submit callback:

&lt;?php
// Make sure you are working with the fully loaded user object.
$account = user_load($GLOBALS['user']-&gt;uid);
$edit['data']['your_stuff'] = $whatever;
user_save($account, $edit);
?&gt;


FYI: user_save() is no more in Drupal 8 and instead behaves like all other entity save functions/methods in 8.x, by calling $account->save() after changing $account. See the following change record for details: http://drupal.org/node/1554986