Saving form data of forms modified with form_alter hook I understand how to add stuff like checkboxes and fieldsets to existing forms (e.g. the form displayed on the node edit page) using _form_alter. But what I don't understand is how to collect the input and store it in a database table of my choosing (ideally with db_insert). Let's say I've added a checkbox to the fieldsets at the bottom of article_node_form (the form which appears when editing content type article):

$form["Email Notifications"] = array(
    '#type' =&gt; 'fieldset',
    '#title' =&gt; 'Email Notifications',
    '#collapsible' =&gt; 'true',
    '#group' =&gt; 'additional_settings',
    '#required' =&gt; FALSE,
    'email_notify' =&gt; array (
        '#type' =&gt; 'checkbox',
        '#title' =&gt; 'Notify users of changes to this page',
        '#default_value' =&gt; 0,
        '#required' =&gt; FALSE,
)


How do I collect this data an store it in a database?
Exactly like you alter a form to add custom fields, you alter it to add custom validation and submit handlers.

It should be:

$form['#validate][] = 'custom_validate';
$form['#submit'][] = 'custom_submit';


use those function to control the additional user input and store them later.