0

I would like to add customer email to order confirmation email, but can't figure out how to do that. Is there any predefined variable that i can use in Transactional email templates or what does it take in order get customer email in each order confirmation email?

1
<p >{{trans "Customer Email," customer_email=$order.getCustomerEmail()}}</p>
|improve this answer|||||
0

You can get customer email by below line,

{{var order.getCustomerEmail()}}
|improve this answer|||||
0

Used in email template:

{{var customer.email}}
|improve this answer|||||
0

Juste use {{var}} or {{trans}} :

<h2>{{trans "Dear, %name" name=$customer.name}}</h2>

or

<h2>{{trans "Dear,"}} {{var $customer.name}}</h2>
|improve this answer|||||
0

Both {{var order.customer_email}} and {{var order.getCustomerEmail()}} working in 2.3.4.

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.