Filter hook 'get_network'

in WP Core File wp-includes/ms-network.php at line 48

View Source

get_network

Filter Hook
Description
Fires after a network is retrieved.

Hook Information

File Location wp-includes/ms-network.php View on GitHub
Hook Type Filter
Line Number 48

Hook Parameters

Type Name Description
WP_Network $_network Network data.

Usage Examples

Basic Usage
<?php
// Hook into get_network
add_filter('get_network', 'my_custom_filter', 10, 1);

function my_custom_filter($_network) {
    // Your custom filtering logic here
    return $_network;
}

Source Code Context

wp-includes/ms-network.php:48 - How this hook is used in WordPress core
<?php
  43  	 *
  44  	 * @since 4.6.0
  45  	 *
  46  	 * @param WP_Network $_network Network data.
  47  	 */
  48  	$_network = apply_filters( 'get_network', $_network );
  49  
  50  	return $_network;
  51  }
  52  
  53  /**

PHP Documentation

<?php
/**
	 * Fires after a network is retrieved.
	 *
	 * @since 4.6.0
	 *
	 * @param WP_Network $_network Network data.
	 */
Quick Info
  • Hook Type: Filter
  • Parameters: 1
  • File: wp-includes/ms-network.php
Related Hooks

Related hooks will be displayed here in future updates.