LLMS_Settings_Notifications::after_save()

Send a test notification after notification data is saved


Return Return

(void)


Top ↑

Source Source

File: includes/admin/settings/class.llms.settings.notifications.php

	/**
	 * Send a test notification after notification data is saved
	 *
	 * @since 3.24.0
	 * @since 3.35.0 Verify nonce & Sanitize input data.
	 *
	 * @return void
	 */
	public function after_save() {

		if ( ! llms_verify_nonce( '_wpnonce', 'lifterlms-settings' ) ) {
			return;
		}

		if ( isset( $_GET['notification'] ) && isset( $_GET['type'] ) && isset( $_POST['llms_notification_test_data_temp'] ) ) {

			if ( ! empty( $_POST['llms_notification_test_data_temp'] ) ) {

				$controller = LLMS()->notifications()->get_controller( llms_filter_input( INPUT_GET, 'notification', FILTER_SANITIZE_STRING ) );
				$controller->send_test(


Top ↑

Changelog Changelog

Changelog
Version Description
3.35.0 Verify nonce & Sanitize input data.
3.24.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.