WordPress at a glance
function is not described

wp_cache_get_multiple() WP 5.5.0

Retrieves multiple values from the cache in one call.

Compat function to mimic wp_cache_get_multiple().

No Hooks.

Return

Array. Array of values organized into groups.

Usage

wp_cache_get_multiple( $keys, $group, $force );
$keys(array) (required)
Array of keys under which the cache contents are stored.
$group(string)
Where the cache contents are grouped.
Default: ''
$force(true/false)
Whether to force an update of the local cache from the persistent cache.
Default: false

Notes

  • See: wp_cache_get_multiple()

Changelog

Since 5.5.0 Introduced.

Code of wp_cache_get_multiple() WP 5.5.1

<?php
function wp_cache_get_multiple( $keys, $group = '', $force = false ) {
	$values = array();

	foreach ( $keys as $key ) {
		$values[ $key ] = wp_cache_get( $key, $group, $force );
	}

	return $values;
}