public/wordpress/wp-content/plugins/wp-courseware/includes/core/admin.php
/**
	 * Dismiss Admin Notices.
	 *
	 * There are various admin notices that
	 * need to be dismissed when displayed.
	 * This method takes care of those.
	 *
	 * @since 4.3.0
	 */
Dismiss Admin Notices.
There are various admin notices that
need to be dismissed when displayed.
This method takes care of those.


Dismiss Admin Notices . There are various admin notices that need to be dismissed when displayed . This method takes care of those .
public function dismiss_notices() {
		$current_user = wp_get_current_user();
		if ( isset( $_GET['wpcw_perma_notice_hide'] ) && '1' == $_GET['wpcw_perma_notice_hide'] ) {
			add_user_meta( $current_user->ID, 'ignore_permalinks_notice', 'yes', true );
		}
		if ( isset( $_GET['wpcw_cancelled_lic_notice_hide'] ) && '1' == $_GET['wpcw_cancelled_lic_notice_hide'] ) {
			add_user_meta( $current_user->ID, 'ignore_cancelled_license_notice', 'yes', true );
		}
		if ( isset( $_GET['wpcw_expired_lic_notice_hide'] ) && '1' == $_GET['wpcw_expired_lic_notice_hide'] ) {
			add_user_meta( $current_user->ID, 'ignore_expired_license_notice', 'yes', true );
		}
	}
public function dismiss_notices ( ) { $ current_user = wp_get_current_user ( ) ; if ( isset ( $ _GET [ 'wpcw_perma_notice_hide' ] ) && '1' == $ _GET [ 'wpcw_perma_notice_hide' ] ) { add_user_meta ( $ current_user -> ID , 'ignore_permalinks_notice' , 'yes' , true ) ; } if ( isset ( $ _GET [ 'wpcw_cancelled_lic_notice_hide' ] ) && '1' == $ _GET [ 'wpcw_cancelled_lic_notice_hide' ] ) { add_user_meta ( $ current_user -> ID , 'ignore_cancelled_license_notice' , 'yes' , true ) ; } if ( isset ( $ _GET [ 'wpcw_expired_lic_notice_hide' ] ) && '1' == $ _GET [ 'wpcw_expired_lic_notice_hide' ] ) { add_user_meta ( $ current_user -> ID , 'ignore_expired_license_notice' , 'yes' , true ) ; } }
Dismiss Admin Notices.
Dismiss Admin Notices .
// If dismiss button has been clicked, user meta field is added // Dismiss canceled license notice // Dismiss expired license notice