You can create an additional submission callback. Not sure if it will run late enough for you. May be worth a shot.
Create a form alter hook using hook_form_alter();
Within there add an additional submit function to the #submit array
Example:
hook_form_alter(&$form, &$form_state, $form_id) {
$form['#submit'][] = 'custom_submit_function';
}
function custom_submit_function($form, &$form_state) {
drupal_set_message('your message');
}
You could try going 1 step further and adding the submit hook to #submit in the #after_build. This will ensure it is the very last submit callback (unless other higher weighted modules also use the afterbuild)
Example:
hook_form_alter(&$form, &$form_state, $form_id) {
$form['#after_build'][] = 'custom_afterbuild_function';
}
function custom_afterbuild_function($form, &$form_state) {
$form['#submit'][] = 'custom_submit_function';
}
function custom_submit_function($form, &$form_state) {
drupal_set_message('your message');
}
I hope this helps
[update] added drupal_set_messages to code examples.
drupal_set_message
?drupal_set_message
. I'd like to know if there's a hook I can call after the form has been saved to database but before the redirect.hook_node_insert()
andhook_node_update()
for node API methods, orhook_form_alter()
if you'd rather alter the submission of the node add/edit form itself