do_action( 'ms_site_not_found', WP_Network $current_site, string $domain, string $path )
- Since
- 3.9.0
Fires when a network can be determined but a site cannot.
Description
At the time of this action, the only recourse is to redirect somewhere and exit. If you want to declare a particular site, do so earlier.
Compatibility
- WordPress
- since 3.9.0
- 6.7.7
- 6.8.8
- 6.9.7
- 7.0.4
- 7.1.0
Present in every tracked release (6.7.7 to 7.1.0).
Parameters
$current_siteWP_Network- The network that had been determined.
$domainstring- The domain used to search for a site.
$pathstring- The path used to search for a site.
Where this hook fires · 1
wp-includes/ms-load.php:418ms_load_current_site_and_network()
Source code
* @since 3.9.0 * * @param WP_Network $current_site The network that had been determined. * @param string $domain The domain used to search for a site. * @param string $path The path used to search for a site. */ do_action( 'ms_site_not_found', $current_site, $domain, $path ); if ( $subdomain && ! defined( 'NOBLOGREDIRECT' ) ) { // For a "subdomain" installation, redirect to the signup form specifically. $path = 'wp-signup.php?new=' . str_replace( '.' . $current_site->domain, '', $domain ); /** This filter is documented in wp-includes/link-template.php */Changelog
Introduced in 3.9.0. Unchanged from 6.7.7 through 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.
About this page
- Parsed data
- Generated from the wordpress-develop 7.0.4 tag, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.
- Corrections
- Something wrong on this page? Report it and it gets fixed in the next regeneration.