gform_post_notification_save

This hook was removed in version 2.5. gform_post_update_form_meta can be used instead.

Description

Fires after the notification is successfully saved.

Usage

add_action( 'gform_post_notification_save','your_function_name', 10,3 );

Parameters

Example

add_action( 'gform_post_notification_save', 'notification_saved', 10, 3 );
function notification_saved( $notification, $form, $is_new_notification ) {
	if ( $is_new_notification ) {
		$message = 'A new notification was created for form id ' . $form['id'] . ' - ' . $form['title'];
	} else {
		$message = 'A new notification was updated for form id ' . $form['id'] . ' - ' . $form['title'];
	}

	GFCommon::send_email( '[email protected]', '[email protected]', '', '', 'New Notification', $message );
}

Placement

This code should be placed in the functions.php file of your active theme.

Since

This filter was added in Gravity Forms version 1.9.16.

Source Code

This filter is located in GFNotification::notification_edit_page() in notification.php.