translation of characteristic values

  • Posts: 141
  • Thank you received: 3
5 years 4 months ago #301838

-- HikaShop version -- : 4.0.1.
-- Joomla version -- : 3.8.13

Hi, Is it possible to translate Product Characteristic Values to another language ? I have tried using Hikashop-System-Languages-Overrides but unsuccessful. However Overrides is working for the Filter Values and not for the Characteristic Values.
Regards

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

  • Posts: 81515
  • Thank you received: 13069
  • MODERATOR
5 years 4 months ago #301840

Hi,

You can do that with the integration we have with Falang:
demo.hikashop.com/index.php/en/hikashop/...ge/with-translations
Once you enable it, on the characteristic interfaces, you'll have tabs for each language in order to translate the characteristic and its values. You can see it on our demo website backend if you edit a characteristic there.

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

  • Posts: 141
  • Thank you received: 3
5 years 4 months ago #301879

Hi Nicolas, thank you for your response
I will try this solution
Regards,

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

  • Posts: 2
  • Thank you received: 0
5 years 2 months ago #303132

I had something similar but then to the labels of the characteristics in the product view.

I could not use the standard translations method as the JText::_ was missing.
I thought I could find this in the \front\views\product\tmpl\show_block_characteristic.php

Unfortunately it was not there. Iin the end I found it here: \back\types\characteristic.php

In line 228 replace:

$html = $characteristic->characteristic_value.'</td><td>'.$html;

with:
$html = JText::_($characteristic->characteristic_value).'</td><td>'.$html;

Now I can add a HIKA_SHOE_SIZE to my language overrides and see it as "schoenmaat" or "shoe size" in the product page.

Since it cannot be used in template overrides, can this be added in a next version of HikaShop? It is then available for all of us.
I am looking for the similar when it comes to the values... then I can do the same with those instead of adding the extra ballast that comes with Falang...Though it is a good extension, I like to stick as close as possible to the core features of Joomla!

Last edit: 5 years 2 months ago by pietergr. Reason: fix typos and add extra info

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

  • Posts: 81515
  • Thank you received: 13069
  • MODERATOR
5 years 2 months ago #303162

Hi,

It's not that it was "missing".
It's that it was never meant to be possible.
But it's indeed a good idea. We'll add some code to handle the translation of characteristics name and values via joomla translation keys for the next version. Thanks for your feedback.

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

  • Posts: 141
  • Thank you received: 3
4 years 10 months ago #307261

Hi Nicolas, I am using Hikashop Business ver. 4.1 and in the change log list of improvements is information “It is now possible to translate characteristics names and values using Joomla language keys.”. I made successfully translation of characteristics names using language override (simply typing in the override box ENGLISH_NAME=”Translated Name” - same works for custom field label and custom field value ) but I don’t know how to do translation od characteristics values – could you explain how it should be done?
Regards,
Greg

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

  • Posts: 81515
  • Thank you received: 13069
  • MODERATOR
4 years 10 months ago #307262

Hi,

It's the same. You add the translation key in the override box and then use it in the characteristic value instead of the text you normally put there.

The following user(s) said Thank You: Greg_C

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

  • Posts: 141
  • Thank you received: 3
4 years 10 months ago #307298

Hi Nicolas, ok, thank you for the information - it works !
Regards,
Greg

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

  • Posts: 141
  • Thank you received: 3
4 years 9 months ago #308002

Hi Nicolas, I cannot find the way how to translate Custom Filter Name (I have tried the same way as for Name and Values of Characteristics and Custom Fields but unsuccessfuly) - could you give mi a hint ?
Regards,
Greg

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

  • Posts: 81515
  • Thank you received: 13069
  • MODERATOR
4 years 9 months ago #308007

Hi,

Well, it's the same than will characteristic values. So far it's not possible if you don't have Falang.
But we could also add that capability in the future.

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

  • Posts: 141
  • Thank you received: 3
4 years 9 months ago #308033

Hi Nicolas,
Thank you for the information. It would be great if such functionality would be added. Is it possible to add in meantime some code in the filter.php file or in another .php to make available translation of Custom Filter Name through Hikashop Language Override?

Regards,
Greg

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

  • Posts: 81515
  • Thank you received: 13069
  • MODERATOR
4 years 9 months ago #308060

Hi,

It's possible to add some code in the meantime, but it's not that easy. There are several places where you need to change the code and it's in administrator/components/com_hikashop/classes/filter.php so you can't do it as a view override.

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

Time to create page: 0.089 seconds
Powered by Kunena Forum