Closed (fixed)
Project:
Commerce Email
Version:
7.x-2.x-dev
Component:
User interface
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
10 Feb 2012 at 21:42 UTC
Updated:
5 Sep 2012 at 20:53 UTC
Hello There!
.. can someone tell me where get the commerce-order-email.tpl.php ?
it is not in the commerce_email/theme ?
Where can i change the order emails?
Thanks for any advice!
Comments
Comment #1
sorensong commentedI have the same question. Lost.
Comment #2
liupascal commented2.x uses HtmlMail to handle the theming part, so you'll have to create a template for HtmlMail.
With Commerce Email, it seems like the workflow looks like this :
1/ Commerce Email declares a new token that contains the themed order content information,
2/ Commerce Email uses Variable Email and Rules to send the email
3/ The Mail System module is used to define the mail processor (HtmlMail) to be used for Variable Email.
So at the end : when an order is completed for instance, Rules triggers the "Send a Variable Email" action, which has the order content token, and the email text in a variable (set in admin/commerce/config/email) - Since Variable Email is set to use HtmlMail mail processor, it themes the email with the default theme provided by HtmlMail.
If you want to create a specific template for your email, you'll have to do something like this :
- Create a template email in your theme used for your email (See admin/config/system/htmlmail) with the following template name : htmlmail--variable_email--EMAIL_KEY.tpl.php where EMAIL_KEY is the variable name used (try htmlmail--variable_email--commerce_email_order.tpl.php for the default one).
For more help on the template name suggestion system of HtmlMail, go to admin/config/system/htmlmail and check "debug" checkbox, send an email and you'll see what should be your EMAIL_KEY.
Comment #3
Robin Millette commentedComment #5
technikh commentedsomehow my email was showing html code. I fixed it by the below code.
Comment #6
LonitaD commentedIt would be helpful if you put the information in #2 in a readme.txt, or at least a link to the documentation on drupal.org.