Perform action once a form has been validated On Drupal 7, I would like to execute some code once a form has been validated.

I have seen many usage of hook_form_FORM_ID_alter : implementing this hook and adding a custom callback to $form['#validate'] I could perform action on validation.

But I need to be absolutely sure the form has been validated to perform my actions.

Is there some other hook to do so ? Or something I could do in hook_form_alter to ensure that ?
You should add a submit callback instead of a validation callback. Submit callbacks are called after the form has been validated.

function yourmodule_form_FORM_ID_alter(&amp;$form, &amp;$form_state) {
  $form['#submit'][] = 'yourmodule_custom_submit_callback';
}

function yourmodule_custom_submit_callback($form, &amp;$form_state) {
  // Execute here your code
}