ms_network_not_found
Fires when a network cannot be found based on the requested domain and path.
Description
At the time of this action, the only recourse is to redirect somewhere and exit. If you want to declare a particular network, do so earlier.
Parameters (2)
- 0. $domain (string)
- The domain used to search for a network.
- 1. $path (string)
- The path used to search for a path.
Usage
- To run the hook, copy the example below.
- // run the action
- do_action( 'ms_network_not_found', $domain, $path );
- The following example is for adding a hook callback.
- // define the ms_network_not_found callback
- function action_ms_network_not_found( $domain, $path ) {
- // make action magic happen here...
- };
- // add the action
- add_action( 'ms_network_not_found', 'action_ms_network_not_found', 10, 2 );
- To remove a hook callback, use the example below.
- // remove the action
- remove_action( 'ms_network_not_found', 'action_ms_network_not_found', 10, 2 );
Defined (2)
The action is defined in the following location(s).
- /wp-includes/ms-load.php
- do_action( 'ms_network_not_found', $domain, $path );
- do_action( 'ms_network_not_found', $domain, $path );