Filters the value of any existing network option before it is retrieved. Returning a value other than false from the filter will short-circuit retrieval and return that value instead.
$pre, $option, $network_id, $default_value
Sortie :
@param mixed $pre_option The value to return instead of the network option value. This differs @param string $option Name of the option. @param int $network_id ID of the network. @param mixed $default_value The fallback value to return if the option does not exist.
// Modifier la valeur avec le filtre 'pre_site_option'
add_filter('pre_site_option', 'ma_fonction_filtre', 10, 1);
function ma_fonction_filtre($pre) {
// Modifier la valeur
return $pre;
}
Chargement des actualités...