strange language change during checkout

  • Posts: 29
  • Thank you received: 1
  • Hikashop Business
9 years 3 months ago #228374

-- HikaShop version -- : 2.6.1
-- Joomla version -- : 3.4.8
-- Browser(s) name and version -- : div
-- Error-message(debug-mod must be tuned on) -- : (none)

I have setup a bilingual webshop German/English, and it runs fine.
There is only one strange thing, I can't figure out why:
When someone goes through the checkout process on the English page, the last step is in German. The page itself stays in English. All steps (login/ address entry, payment method, confirmation, etc.) was in English but when it comes to the actual payment step, the shop seems to switch to German. It is independent from the payment method.
I have documented all four steps in my checkout process with screenshots. As you can see, in steps 1-3 the checkout progress bar is in English (1. "start", 2. "payment method", 3. "confirmation", 4. "end") but in step 4, it switches to German ("1. start", 2. "zahlungsmethode", 3. "übersicht", 4. "bestellbestätigung").
Any idea? Thanks for your help.









Chris


________________________________
CSK Management

www.cskmanagement.com
Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 4820
  • Thank you received: 654
  • MODERATOR
9 years 3 months ago #228394

Hello,

Did you notice some change in your url? I mean do you have this kind of difference :

index.php/fr/hikashop-menu-for-products-listing/checkout/task-step/step-1
To

index.php/en-us/hikashop-menu-for-products-listing/checkout/task-step/step-2

or other stuff like this example, maybe that can be link to your canonical Url and so try switch it off.
Hope this will help you.

Regards,

Last edit: 9 years 3 months ago by Philip.

Please Log in or Create an account to join the conversation.

  • Posts: 29
  • Thank you received: 1
  • Hikashop Business
9 years 3 months ago #228478

Hi Philippe
- thanks for the fast reply.
I have checked the URL, they do not change the language (still "en").

Regarding the canonical URL: do you mean the canonical URL in the product definition? I have deleted the canonical URL in one of my products, but unfortunately no success... Where did you mean I should switch it off?

Given the fact that the rest of the page is still in the English version, it doesn't seem that it's changing the overall language.


________________________________
CSK Management

www.cskmanagement.com

Please Log in or Create an account to join the conversation.

  • Posts: 83806
  • Thank you received: 13571
  • MODERATOR
9 years 3 months ago #228515

Hi,

We're never had that issue.
What payment methods are you using on your website ? Do you have the same problem with all the payment methods on the end step ?
I guess that some plugin must be changing the language of the page in the middle of the processing when the order is being created. So maybe disabling them one by one and testing each time could help identify the source of the problem, especially with the "hikashop", "hikashoppayment" and "system" plugins.

Please Log in or Create an account to join the conversation.

  • Posts: 29
  • Thank you received: 1
  • Hikashop Business
9 years 3 months ago #228540

strange, isn't it?
It is with all the payment methods (stripe credit card, PayPal, invoice and pre-payment).
I will try disabling them, and I will let you know.

thanks so far,
Chris


________________________________
CSK Management

www.cskmanagement.com

Please Log in or Create an account to join the conversation.

  • Posts: 29
  • Thank you received: 1
  • Hikashop Business
9 years 3 months ago #228544

I found the issue, although I haven't solved it, yet.
You guys are really good!
It wasn't a payment plugin. It's the "Attach Invoice to the order confirmation e-mail" plugin. I have now tested it several times with different products and different payment methods. When I disable it, it will work fine!
Any idea, how to solve this (because I definitely need the invoice in the confirmation e-mail)?

regards,
Chris


________________________________
CSK Management

www.cskmanagement.com

Please Log in or Create an account to join the conversation.

  • Posts: 83806
  • Thank you received: 13571
  • MODERATOR
9 years 3 months ago #228607

Hi,

Interesting.
The file you want to look at is plugins/hikashop/attachinvoice/attachinvoice.php
There, you have twice the code:
$class->loadLocale($order);
and the code:
if(method_exists($class,'loadBackLocale')){
$class->loadBackLocale();
}else{
$this->loadBackLocale($class);

}

remove them and try again.
These change the language of the page on the fly in order to generate the invoice in the language of the user and then revert back the language to what it was.

That's however a bit strange since the invoice generation process of the plugin is called just before the email is sent and at that point it has already been generated. so I don't see why the plugin would influence the language of the email.

The following user(s) said Thank You: cskmanagement

Please Log in or Create an account to join the conversation.

  • Posts: 29
  • Thank you received: 1
  • Hikashop Business
9 years 3 months ago #228654

Bingo! Yes, that worked out!
Thanks a lot for this excellent support!!!

One last question: will that file be overwritten when I update HikaShop the next time so that I have to remove the code again?

regards,
Chris


________________________________
CSK Management

www.cskmanagement.com

Please Log in or Create an account to join the conversation.

  • Posts: 83806
  • Thank you received: 13571
  • MODERATOR
9 years 3 months ago #228660

Hi,

No. The plugin is not included in HikaShop. So you won't loose the change when you update HikaShop.

Please Log in or Create an account to join the conversation.

Time to create page: 0.089 seconds
Powered by Kunena Forum