wpseek.com
Un motore di ricerca WordPress per sviluppatori e autori di temi
wp_cache_set_salted › WordPress Function
Da6.9.0
Deprecaton/a
› wp_cache_set_salted ( $cache_key, $data, $group, $salt, $expire = 0 )
| Parametri: (5) |
|
| Ritorna: |
|
| Definito a: |
|
| Codex: |
Stores salted data in the cache.
Funzioni correlate: wp_cache_get_salted, wp_cache_set_multiple_salted, wp_cache_set_multiple, wp_cache_get_multiple_salted, wp_cache_set
Sorgenti
function wp_cache_set_salted( $cache_key, $data, $group, $salt, $expire = 0 ) {
$salt = is_array( $salt ) ? implode( ':', $salt ) : $salt;
return wp_cache_set(
$cache_key,
array(
'data' => $data,
'salt' => $salt,
),
$group,
$expire
);
}
endif;
if ( ! function_exists( 'wp_cache_get_multiple_salted' ) ) :
/**
* Retrieves multiple items from the cache, only considering valid and unchanged items.
*
* @since 6.9.0
*
* @param array $cache_keys Array of cache keys to retrieve.
* @param string $group The group of the cache to check.
* @param string|string[] $salt The timestamp (or multiple timestamps if an array) indicating when the cache group(s) were last updated.
* @return array An associative array containing cache values. Values are `false` if they are not found or outdated.
*/