Tribe__PUE__Notices::add_notice( string $notice_type, string $plugin_name )
Used to include a plugin in a notification.
Contents
For example, this could be used to add "My Plugin" to the expired license key notification by passing TribePUENotices::EXPIRED_KEY as the second param.
Plugins can only be added to one notification group at a time, so if a plugin was already added to the MISSING_KEY group and is subsequently added to the INVALID_KEY group, the previous entry (under MISSING_KEY) will be cleared.
Parameters
- $notice_type
-
(string) (Required)
- $plugin_name
-
(string) (Required)
Source
File: src/Tribe/PUE/Notices.php
public function add_notice( $notice_type, $plugin_name ) {
$this->clear_notices( $plugin_name, true );
$this->notices[ $notice_type ][ $plugin_name ] = true;
$this->save_notices();
}