wpmu_new_blog action-hookWP 3.0.0

Deprecated from version 5.1.0. It is no longer supported and can be removed in future releases. See wp_insert_site.

Deprecated: 5.1.0 Use {@see 'wp_insert_site'} instead.

Fires immediately after a new site is created.

Usage

add_action( 'wpmu_new_blog', 'wp_kama_wpmu_new_blog_action', 10, 3 );

/**
 * Function for `wpmu_new_blog` action-hook.
 * 
 * @param int    $site_id Site ID.
 * @param int    $user_id User ID.
 * @param string $domain  Site domain.
 *
 * @return void
 */
function wp_kama_wpmu_new_blog_action( $site_id, $user_id, $domain ){

	// action...
}
$site_id(int)
Site ID.
$user_id(int)
User ID.
$domain(string)
Site domain.

Changelog

Since 3.0.0 Introduced.
Deprecated Since 5.1.0 Use {@see 'wp_insert_site'} instead.

Where the hook is called

wp_insert_site()
wpmu_new_blog
wp-includes/ms-site.php 135-140
do_action_deprecated(
	'wpmu_new_blog',
	array( $new_site->id, $user_id, $new_site->domain, $new_site->path, $new_site->network_id, $meta ),
	'5.1.0',
	'wp_insert_site'
);

Where the hook is used in WordPress

Usage not found.