wp_insert_site WordPress Action Hook
The wp_insert_site hook is called when a new site is created in a WordPress network. It allows for custom code to be executed when a new site is created, such as sending a notification email or creating a custom database entry.
do_action( 'wp_insert_site', WP_Site $new_site ) #
Fires once a site has been inserted into the database.
Parameters
- $new_site
(WP_Site)New site object.
Source
File: wp-includes/ms-site.php
Changelog
Version | Description |
---|---|
5.1.0 | Introduced. |