woocommerce_cached_widget_id

FILTER woocommerce\includes\abstracts\abstract-wc-widget.php (ligne 406) github
Get widget id plus scheme/protocol to prevent serving mixed content from (persistently) cached widgets.

Paramètres

Entrée :
$widget_id_for_cache
Sortie :
@param  string $widget_id Id of the cached widget.
@param  string $scheme    Scheme for the widget id.
@return string            Widget id including scheme/protocol.

Utilisation

// Modifier la valeur avec le filtre 'woocommerce_cached_widget_id'
add_filter('woocommerce_cached_widget_id', 'ma_fonction_filtre', 10, 1);

function ma_fonction_filtre($widget_id_for_cache) {
    // Modifier la valeur
    return $widget_id_for_cache;
}

Actualités

Chargement des actualités...