site_transient_(transient) хук-фильтрWP 2.9.0

Filters the value of an existing site transient.

The dynamic portion of the hook name, $transient, refers to the transient name.

Использование

add_filter( 'site_transient_(transient)', 'wp_kama_site_transient_filter', 10, 2 );

/**
 * Function for `site_transient_(transient)` filter-hook.
 * 
 * @param mixed  $value     Value of site transient.
 * @param string $transient Transient name.
 *
 * @return mixed
 */
function wp_kama_site_transient_filter( $value, $transient ){

	// filter...
	return $value;
}
$value(разное)
Value of site transient.
$transient(строка)
Transient name.

Список изменений

С версии 2.9.0 Введена.
С версии 4.4.0 The $transient parameter was added.

Где вызывается хук

get_site_transient()
site_transient_(transient)
wp-includes/option.php 2336
return apply_filters( "site_transient_{$transient}", $value, $transient );

Где используется хук в WordPress

Использование не найдено.