Post by ransom1 » Fri Nov 26, 2021 8:44 am

Hi guys,
I am trying to change the emails that Opencart sends to customers. Specifically the order_edit email. I updated the twig in catalog\view\theme\default\template\mail\order_edit.twig and I also updated the text contained in catalog\language\en-gb\mail\order_edit.php
I refreshed the template cache. I tried editing the twig file from the Theme editor.
Despite all these changes, the email stays exactly the same. No text nor twig layout changes are reflected.
What am I doing wrong?

Newbie

Posts

Joined
Mon Jul 14, 2014 6:20 pm

Post by grgr » Fri Nov 26, 2021 11:12 am

If you are trying to edit the email that is sent when you add order history and notify customer, then that is the correct file.

Delete the changes made in the theme editor and just edit the template file, you should see the changes in the email.

Also refresh the modification cache, if that file has been changed by an OCMOD.

-
Image Image Image Image
VIEW ALL EXTENSIONS * EXTENSION SUPPORT * WEBSITE * CUSTOM REQUESTS


User avatar
Active Member

Posts

Joined
Mon Mar 28, 2011 4:08 pm
Location - UK

Post by ransom1 » Fri Nov 26, 2021 11:31 am

edit the template file, you should see the changes in the email
I should, but I'm not. I even tried deleting order_edit.twig from the server and the email still sends! Where is it coming from?

I changed it and refreshed template, sass and mods. Then I deleted it and refreshed the same, and the email still sends, exactly the same.

Newbie

Posts

Joined
Mon Jul 14, 2014 6:20 pm

Post by ransom1 » Fri Nov 26, 2021 12:02 pm

I think I'm going insane. I deleted order_edit.twig from the server. I went into the storage/cache on the server and deleted everything. Then I deleted catalog\controller\mail\order.php and the email STILL WORKS. How? When I update the order status and tick to notify customer it still sends. I'm totally lost.

Newbie

Posts

Joined
Mon Jul 14, 2014 6:20 pm

Post by thekrotek » Fri Nov 26, 2021 1:43 pm

One word: caching.

Professional OpenCart extensions, support and custom work.
Contact me via email or Skype by support@thekrotek.com


User avatar
Expert Member

Posts

Joined
Sun Jul 03, 2016 12:24 am


Post by hpwebdesign » Fri Nov 26, 2021 2:55 pm

I think the order_edit.twig and order_edit.php edit files have been changed by OCMOD or VQMOD
refresh modifications in menu extensions->modifications
if there is no change then the file is changed by vqmod

HP Web Design
http://hpwebdesign.io
Opencart Extension Development | OpenCart Professional Services | OpenCart Tutorials


User avatar
New member

Posts

Joined
Wed Aug 15, 2018 6:58 am
Location - Yogyakarta

Post by paulfeakins » Mon Nov 29, 2021 7:39 pm

thekrotek wrote:
Fri Nov 26, 2021 1:43 pm
One word: caching.
Image
https://www.antropy.co.uk/blog/how-to-c ... t-3-0-2-0/

UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk


User avatar
Guru Member
Online

Posts

Joined
Mon Aug 22, 2011 11:01 pm
Location - London Gatwick, United Kingdom

Post by fredJ » Mon Jan 30, 2023 6:05 pm

I struggled with this too.
Eventually decided to just rename the file order_edit to order_edit2, and in order.php change this line like this
$mail->setText($this->load->view('mail/order_edit2', $data));
It seems to get cached again, so change it to order_edit3 if you need to change again.

Newbie

Posts

Joined
Fri Jan 18, 2019 11:10 pm
Who is online

Users browsing this forum: DesignCart, JNeuhoff and 101 guests