- Posts: 17
- Thank you received: 3
Problems with order confirmation emails language
4 years 10 months ago - 4 years 10 months ago #336959
by fullwater
Problems with order confirmation emails language was created by fullwater
-- HikaShop version -- : 4.4.4
-- Joomla version -- : 3.10.3
-- PHP version -- : 7.4.24
Hello,
i have a website in italian and english where italian is the default language.
The link in the order confirmation mail sent to the users, points to the english version of the site even if the order was placed in Italian.
What am i missing?
Thank in advance
-- Joomla version -- : 3.10.3
-- PHP version -- : 7.4.24
Hello,
i have a website in italian and english where italian is the default language.
The link in the order confirmation mail sent to the users, points to the english version of the site even if the order was placed in Italian.
What am i missing?
Thank in advance
Last edit: 4 years 10 months ago by fullwater.
Please Log in or Create an account to join the conversation.
4 years 10 months ago #336961
by nicolas
Replied by nicolas on topic Problems with order confirmation emails language
Hi,
I think it's a problem in the code.
In the file administrator/components/com_hikashop/classes/order.php we have this code:
The call to the loadLocale function is what properly sets the current language to the language of the customer. But it is placed after the line setting $order->order_url which contains the URL of the order.
So I think this code should be changed to swap both lines, like this:
It should then generate a link with the correct language.
I think it's a problem in the code.
In the file administrator/components/com_hikashop/classes/order.php we have this code:
Code:
$order->order_url = hikashop_contentLink('order&task=show&cid[]='.$order->order_id.$url, $order, false, false, false, true);
$app = JFactory::getApplication();
$locale = $this->loadLocale($order);
So I think this code should be changed to swap both lines, like this:
Code:
$locale = $this->loadLocale($order);
$order->order_url = hikashop_contentLink('order&task=show&cid[]='.$order->order_id.$url, $order, false, false, false, true);
$app = JFactory::getApplication();
The following user(s) said Thank You: fullwater
Please Log in or Create an account to join the conversation.
4 years 10 months ago #336981
by fullwater
Replied by fullwater on topic Problems with order confirmation emails language
Hi Nicolas, it works, thank You.
Are you planning to fix the code on next release or i'll have to change manually those lines on every single update?
Are you planning to fix the code on next release or i'll have to change manually those lines on every single update?
Please Log in or Create an account to join the conversation.
4 years 10 months ago #336988
by nicolas
Replied by nicolas on topic Problems with order confirmation emails language
Hi,
The modification is added on our end for the next version of HikaShop, so no worries.
The modification is added on our end for the next version of HikaShop, so no worries.
The following user(s) said Thank You: fullwater
Please Log in or Create an account to join the conversation.
4 years 10 months ago #337035
by fullwater
Replied by fullwater on topic Problems with order confirmation emails language
Nice of you. Thank you.
Please Log in or Create an account to join the conversation.
Time to create page: 0.230 seconds