- Posts: 139
- Thank you received: 1
Custom entry in E-mails on order change
12 years 3 months ago #162202
by abasel
Custom entry in E-mails on order change was created by abasel
I am wanting to add another field in the dictionary called
CUSTOMMESSAGE="My custom message"
I want this message to be displayed in the email that is sent out when the order status is changed to "Confirmed"
How do I go about this?
CUSTOMMESSAGE="My custom message"
I want this message to be displayed in the email that is sent out when the order status is changed to "Confirmed"
How do I go about this?
Please Log in or Create an account to join the conversation.
12 years 3 months ago #162215
by nicolas
Replied by nicolas on topic Custom entry in E-mails on order change
Hi,
The simplest is to directly write your text in the order status notification email template that you can edit in the HTML version area of the email via the menu System>Emails.
And if you want to use translations, then you want to add instead such code in there:
<?php echo JText::_('CUSTOMMESSAGE'); ?>
and then add your translation line to the override area of your HikaShop translation file via the Languages tab of the HikaShop configuration.
The simplest is to directly write your text in the order status notification email template that you can edit in the HTML version area of the email via the menu System>Emails.
And if you want to use translations, then you want to add instead such code in there:
<?php echo JText::_('CUSTOMMESSAGE'); ?>
and then add your translation line to the override area of your HikaShop translation file via the Languages tab of the HikaShop configuration.
Please Log in or Create an account to join the conversation.
12 years 2 months ago #162335
by abasel
Replied by abasel on topic Custom entry in E-mails on order change
Ok, just one more question on this part. I am only wanting this custom message to display when the Purchase status changes to "confirmed"
What would the PHP if statement look like? I have looked at the code but seem to be missing the part that deals with the status.
What would the PHP if statement look like? I have looked at the code but seem to be missing the part that deals with the status.
Please Log in or Create an account to join the conversation.
Less
More
- Posts: 12953
- Thank you received: 1778
12 years 2 months ago #162337
by Mohamed Thelji
Replied by Mohamed Thelji on topic Custom entry in E-mails on order change
Hello,
The solution will be to use some php code like :
Note that you'll have to replace the "YOUR_STATUS" string by the order status.
The solution will be to use some php code like :
Code:
<?php
if ($data->oder_status == 'YOUR_STATUS' )echo JText::_('CUSTOMMESSAGE');
?>
Note that you'll have to replace the "YOUR_STATUS" string by the order status.
Please Log in or Create an account to join the conversation.
Time to create page: 0.212 seconds