https://youtu.be/-S5SZ5Z7C08
Voici le code à ajouter (regarder la vidéo ci-dessus pour voir la procédure)
function my_email_header( $email_heading, $email ) {
}
add_action( ‘woocommerce_email_header’, ‘my_email_header’, 10, 2 );
function my_order_item_name( $item_name, $item ) {
    $product = wc_get_product( $item[‘variation_id’] ? $item[‘variation_id’] : $item[‘product_id’] );
    $link = get_permalink( $product->get_id() );
    $product_id = $item[‘product_id’];
    $product = wc_get_product( $product_id );
    return  $product->get_image(array( 99, 75 )) . ‘<br><a href=”‘. $link .'”  rel=”nofollow”>’. $item_name .'</a><br><br><p>Référence du produit : ‘ . get_post_meta( $item[‘product_id’], ‘reference’, true ) . ‘</p>’;
}
add_filter( ‘woocommerce_order_item_name’, ‘my_order_item_name’, 10, 2 );