network_admin_url
Filters the network admin URL.
Description
Parameters (2)
- 0. $url (string)
- The complete network admin URL including scheme and path.
- 1. $path (string)
- Path relative to the network admin URL. Blank string if no path is specified.
Usage
- To run the hook, copy the example below.
- $url = apply_filters( 'network_admin_url', $url, $path );
- if ( !empty( $url ) ) {
- // everything has led up to this point...
- }
- The following example is for adding a hook callback.
- // define the network_admin_url callback
- function filter_network_admin_url( $url, $path ) {
- // make filter magic happen here...
- return $url;
- };
- // add the filter
- add_filter( 'network_admin_url', 'filter_network_admin_url', 10, 2 );
- To remove a hook callback, use the example below.
- // remove the filter
- remove_filter( 'network_admin_url', 'filter_network_admin_url', 10, 2 );
Defined (1)
The filter is defined in the following location(s).
- /wp-includes/link-template.php
- return apply_filters( 'network_admin_url', $url, $path );