deactivate_blog
Fires before a network site is deactivated.
Description
Parameters (1)
- 0. $id (string)
- The ID of the site being deactivated.
Usage
- To run the hook, copy the example below.
- // run the action
- do_action( 'deactivate_blog', $id );
- The following example is for adding a hook callback.
- // define the deactivate_blog callback
- function action_deactivate_blog( $id ) {
- // make action magic happen here...
- };
- // add the action
- add_action( 'deactivate_blog', 'action_deactivate_blog', 10, 1 );
- To remove a hook callback, use the example below.
- // remove the action
- remove_action( 'deactivate_blog', 'action_deactivate_blog', 10, 1 );
Defined (1)
The action is defined in the following location(s).
- /wp-admin/network/sites.php
- do_action( 'deactivate_blog', $id );