woocommerce_order_item_cogs_html

FILTER woocommerce\includes\class-wc-order-item.php (ligne 589) github
Filter to customize how the Cost of Goods Sold value for an order item gets rendered to HTML.

Paramètres

Entrée :
$cogs_value_html, $cogs_value, $this
Sortie :
@param string $html The rendered HTML.
@param float $value The cost value that is being rendered.
@param WC_Order_Item $product The order item.

Utilisation

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

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

Actualités

Chargement des actualités...