ap_addon_activation_hook( string $addon, string|array $cb )

Description #

Register a callback function which triggred after activating an addon.

Parameters #

  • $addon
    string (Required) Name of addon.
  • $cb
    string | array (Required) Callback function name.

Source #

File: includes/functions.php

function ap_addon_activation_hook( $addon, $cb ) {
	global $ap_addons_activation;
	$addon = wp_normalize_path( $addon );

	$ap_addons_activation[ $addon ] = $cb;
}

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Add your comment