woocommerce_new_customer_username

FILTER woocommerce\includes\wc-user-functions.php (ligne 304) github
Filter new customer username.

Paramètres

Entrée :
$username, $email, $new_user_args, $suffix
Sortie :
@param string $username      Customer username.
@param string $email         New customer email address.
@param array  $new_user_args Array of new user args, maybe including first and last names.
@param string $suffix        Append string to username to make it unique.

Utilisation

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

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

Actualités

Chargement des actualités...