| ||||||||||
![]() |
Shopping cart software Solutions for online shops and malls | |||||||||
![]() |
![]() |
|
X-Cart Home | ![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
Email Confirmation - Order Status Modification | |||
![]() |
|
|
Thread Tools | Search this Thread |
#1
|
|||||||
|
|||||||
![]() How can one change it so that the order status shows the entire word, instead of the letter in the email confirmations? For example, 'Processed" instead of 'P." I know the variable is '$order_status', but where is it defined?
Will unticking "Enable email notifications for customers about initially placed orders" prevent customers from receiving "I" or "F" email confirmations? Thanks in advance. --------------------------------------------------------------- Versions 3.5 & 3.53 |
|||||||
#2
|
|||||||
|
|||||||
![]() As far as I know the order status will always display in the single letter format.
What I did was create a Smarty template to take care of this. This way I only have the order status descriptions in one location. I created a new file named "modifier.orderstatus_format.php" and placed this file in the "Smarty-2.5.0/plugins" directory. This file contains the following information: <?php /* * Smarty plugin * ------------------------------------------------------------- * Type: modifier * Name: orderstatus_format * Purpose: format order status * Input: string: input order status code * ------------------------------------------------------------- */ function smarty_modifier_orderstatus_format($string) { if ($string == 'I') return 'Not finished'; elseif($string == 'Q') return 'Queued'; elseif($string == 'P') return 'Processed'; elseif($string == 'B') return 'Back ordered'; elseif($string == 'D') return 'Declined'; elseif($string == 'F') return 'Failed'; elseif($string == 'C') return 'Complete'; else return 'Unknown'; } ?> I then changed the line in the file "skin1/mail" from: {$lng.lbl_order_status}: {$order.status} to: {$lng.lbl_order_status}: {$order.status|orderstatus_format} I have run this mod from version 3.3.4 to version 3.5.4 with no problems. I hope this helps. |
|||||||
#3
|
|||||||
|
|||||||
![]() dsparks,
Thanks for the reply. I will try it out and see if it works. |
|||||||
#4
|
|||||||
|
|||||||
![]() Hey dsparks... You a SMART newbie!
But I'm not sure what file you are talking about in skin1/mail ??? I'm running 3.5.5 maybe it's no longer there? Oh.. ok... found it... it's now in /mail/init_order_customer.tpl. |
|||||||
#5
|
|||||||
|
|||||||
![]() dsparks,
The use of the order status code instead of its description has annoyed me also for some time, and its only that there are so many other things to get right in the leadup to going live that has stopped me pursuing this. Anyway, thanks for your posting and guidance which I followed to the tee, by just cut and pasting, and .. it worked flawlessly. Exactly the outcome I wanted. I amended mail/order_invoice.tpl. X-cart would do well to incorporate this as standard .. it just makes so much sense. Thanks again
__________________
Risky V3.5.3 With Options-based inventory tracking mod, by X-cart |
|||||||
|
|||
X-Cart forums © 2001-2020
|