WordPress.org

Codex

Interested in functions, hooks, classes, or methods? Check out the new WordPress Code Reference!

Function Reference/is network admin

Description

This Conditional Tag checks whether the current request is for a network admin screen (wp-admin/network). This is a boolean function, meaning it returns either TRUE or FALSE.

Usage

<?php is_network_admin(); ?>

Parameters

This tag does not accept any parameters.

Return Values

(boolean) 
True on success, false on failure.

Examples

if ( is_network_admin() ) {
	echo "You are viewing a WordPress network administration page";
} else {
	echo "You are <em>not</em> viewing a WordPress network administration page";
}

Notes

is_network_admin() does not indicate whether the user is a super admin or has network administration rights.

Change Log

Since: 3.1.0

Source File

is_network_admin() is located in wp-includes/load.php.

Related

See also index of Function Reference and index of Template Tags.