get_site_option( string $option, mixed $default_value = false, bool $deprecated = true )

Retrieve an option value for the current network based on name of option.


Description

See also


Parameters

$option

(Required) Name of the option to retrieve. Expected to not be SQL-escaped.

$default_value

(Optional) Value to return if the option doesn't exist.

Default value: false

$deprecated

(Optional) Whether to use cache. Multisite only. Always set to true.

Default value: true


Return

(mixed) Value set for the option.


Source

File: wp-includes/option.php

function get_site_option( $option, $default = false, $deprecated = true ) {
	return get_network_option( null, $option, $default );
}

Changelog

Changelog
Version Description
4.4.0 Modified into wrapper for get_network_option()
2.8.0 Introduced.