Multilingual display

  • Posts: 159
  • Thank you received: 12
  • Hikashop Business
2 years 4 months ago #345506

-- url of the page with the problem -- : jouets.idimweb.net
-- HikaShop version -- : 4.6.2
-- Joomla version -- : 4.2.3
-- PHP version -- : 8.1.11

Hi,

I'm developing a multlingual website, French and US.

I have a small issue iwth my fiters in English. Part of them is displayed in French instead of English and I don't know why.

Could you please help?
(Note that your SU access is still enable)

Thanks in advance

Have a great weekend,

Sandra

Attachments:

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

  • Posts: 83338
  • Thank you received: 13476
  • MODERATOR
2 years 4 months ago #345511

Hi,

I'm not sure but the best is to directly enter the translation key in the "title" of the value in your custom field. That way, the system can directly use the translation instead of having to first generate the translation key from the text in the title, which can result in the system not finding the translation. I've done the change for the "Console et Jeux" value and it works now.

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

  • Posts: 159
  • Thank you received: 12
  • Hikashop Business
2 years 4 months ago #345517

Hi Nicolas,

Thanks for your answer. I don't get how to do.
I have the same issue for "Jeux de société" and "Plein Air" and don't understand how to fix it.

Sandra

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

  • Posts: 83338
  • Thank you received: 13476
  • MODERATOR
2 years 4 months ago #345526

Hi,

Edit the custom field Geek that I fixed. There, you can see in the data values area that I entered a translation key in the title of the value with the issue, instead of text. That translation key corresponds to the translation key in the language file overrides you can find under the Languages tab of the HikaShop configuration.

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

  • Posts: 159
  • Thank you received: 12
  • Hikashop Business
2 years 4 months ago #345532

Understood, thanks!

I tried to do like that for the title of the Main Information box, but doesn't seem to work. Any idea why?

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

  • Posts: 83338
  • Thank you received: 13476
  • MODERATOR
2 years 4 months ago #345533

Hi,

If you check the language file in the HikaShop configuration, you can see that the "board game" translation is done with this line:
JEUXDESOCIT="Board games"
So the key to use for the title is JEUXDESOCIT
So replace "Jeux de Société" by JEUXDESOCIT in the title of the custom field and it should work.
Note that this is the title of the custom field. On the filters area, the "Jeux de société" you see there is the name of the filter, not the title of the custom field. So if you want to change it there, you need to change the name of the filter with the translation key.

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

  • Posts: 159
  • Thank you received: 12
  • Hikashop Business
2 years 4 months ago #345550

Got it! Thanks!

Do you know why it works sometimes by entering the translation in the filter/custom field screen and why it doesn't sometimes and then the language key needs to be used to get it right?

It's not an issue for me to use the language key, but then it's my client who will create them and that may be a bit painful for him.

Thanks

Sandra

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

  • Posts: 83338
  • Thank you received: 13476
  • MODERATOR
2 years 4 months ago #345553

That's because the text use special characters, spaces, accents and the system is not able to get the translation from it for some reason.

What you could do is activate the "Non-latin translation keys" setting in the HikaShop configuration.
This will use a hash of the text for translation keys so that it can work fine with special characters.
However, as the mechanism is different, it means that you'll have to redo the translations you already have.

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

  • Posts: 159
  • Thank you received: 12
  • Hikashop Business
2 years 4 months ago #345571

Thanks a lot for your help Nicolas.

It now works like a charm.

Thanks!

Sandra

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

Time to create page: 0.067 seconds
Powered by Kunena Forum