woocommerce_pre_customer_bought_product

FILTER woocommerce\includes\wc-user-functions.php (ligne 408) github
Checks if a user (by email or ID or both) has bought an item.

Paramètres

Entrée :
null, $customer_email, $user_id, $product_id
Sortie :
@param string $customer_email Customer email to check.
@param int    $user_id        User ID to check.
@param int    $product_id     Product ID to check.
@return bool

Utilisation

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

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

Actualités

Chargement des actualités...