Notice_Handler::trigger_admin( string $slug, array $args = array() )

Add an admin notice that should only show once.

See also


Top ↑

Parameters

$slug

(string) (Required) Slug to store the notice.

$args

(array) (Optional) Arguments to set up a notice.

Default value: array()


Top ↑

Source

File: src/Tickets/Commerce/Notice_Handler.php

	public function trigger_admin( $slug, $args = [] ) {

		$message = $this->get_message_data( $slug, $args );

		tribe_transient_notice( $slug, $message['content'], $message, $this->get_expiration( $slug ) );

		// This is here because of a possible bug in common.
		$this->clear_request_cache();
	}

Top ↑

Changelog

Changelog
Version Description
5.2.0 Introduced.