How to add extra text in order e-mail in opencart

Hello i want to change the e-mail answer after a successfull order in my Opencart store.

I just want to add more text in the email.

As far as i know i need to go in :

catalog/view/theme/default/template/mail/order.tpl

and change the code there but when I do so ,nothing changes.

I am so sorry for my bad English.

Upvotes: 0

Views: 710

Answers (2)

Ali Zia
Ali Zia

Reputation: 3875

  1. Go in the language file /catalog/language/*/mail/order.php.

  2. At the end of file, paste this $_['text_new'] = "Your Text";. The model catalog/model/checkout/order.php automatically calls language file so you wont have to call it, but you would have to declare the variable in your model. Go through it and see where mail variables are being made. Add your variable over there. $data['text_new'] = $this->language->get('text_new');

  3. Go to catalog/view/theme/default/template/mail/order.tpl and call your the variable $text_new where ever you need.

That's it.

Upvotes: 1

Frosty
Frosty

Reputation: 334

You are not supposed to go inside the .tpl file

Go here:

/catalog/language/bulgarian/mail/order.php

you will find this line:

$_['text_new_greeting']         = "Your text HERE";

Chnage the text inside the "" marks.

That is for Opencart 1.x (i am not sure for 2.0)

Upvotes: 0

Related Questions