jonas32 LiteCart Fan از کشور Sweden عضو از نوامبر 2018 jonas32 23 مارس 2024 07:36 Hey. I have tried adding my sms code but havnt succeeded made it to work. So can anyone help me where i should place my sms code to send sms when orderstatus is changed. And in what file. Thanks
s22_tech Moderator از کشور United States عضو از اکتبر 2019 s22_tech 23 مارس 2024 14:39 Jonas, I've done basically the same thing, but only for new orders, and have placed the code in includes/entities/ent_order.inc.php just before the second $email = new ent_email(); Marc
jonas32 LiteCart Fan از کشور Sweden عضو از نوامبر 2018 jonas32 23 مارس 2024 14:47 Ah, ok. So if they pay with PayPal sms wont be sent when status is changed to payment received ?
s22_tech Moderator از کشور United States عضو از اکتبر 2019 s22_tech 23 مارس 2024 15:00 If you're talking about LiteCart's order status, then yes. it's doable. You just have to tie into the status change code. Looking more closely at ent_order.inc.php, it appears that you could tie into the following code to trigger your SMS: if (!empty($this->previous) && ($this->data['order_status_id'] != $this->previous['order_status_id'])) { if (!empty(reference::order_status($this->data['order_status_id'])->notify)) { $this->send_email_notification(); } }```
megamiska Merchant از کشور Slovenia عضو از اکتبر 2023 megamiska 23 مارس 2024 18:40 Which SMS provider do you use?
jonas32 LiteCart Fan از کشور Sweden عضو از نوامبر 2018 jonas32 24 مارس 2024 19:52 yes, it worked, thanks a lot. I did like this $this->send_email_notification(); } // <-- closed it here if ($current_order_status['id'] == 3 && $current_order_status['id'] != $previous_order_status['id']) { // added this My sms code goes here