- Posts: 141
- Thank you received: 3
characteristics variants (values) translation
7 years 1 month ago #310954
by Greg_C
characteristics variants (values) translation was created by Greg_C
-- HikaShop version -- : 4.2.1
-- Joomla version -- : 3.9.8
-- PHP version -- : 7.2.14
Hello, I have question regarding products characteristics variants (values) translation. I have checked that It is possible to do translation of characteristics variants (values) presented on product page in list of values as dropdown list (product / show_block_characteristic.php) – translation is done using System-Configuration-Languages. Unfortunately this translation doesn’t work for characteristics variants (values) presented in hikashop_product_variant_subname on product page (product / show_tabular.php) and presented in the cart (checkout / show_block_cart.php).
How can I make characteristics variants (values) translation working not only for product / show_block_characteristic.php but also for product / show_tabular.php and checkout / show_block_cart.php ?
Regards,
Greg
-- Joomla version -- : 3.9.8
-- PHP version -- : 7.2.14
Hello, I have question regarding products characteristics variants (values) translation. I have checked that It is possible to do translation of characteristics variants (values) presented on product page in list of values as dropdown list (product / show_block_characteristic.php) – translation is done using System-Configuration-Languages. Unfortunately this translation doesn’t work for characteristics variants (values) presented in hikashop_product_variant_subname on product page (product / show_tabular.php) and presented in the cart (checkout / show_block_cart.php).
How can I make characteristics variants (values) translation working not only for product / show_block_characteristic.php but also for product / show_tabular.php and checkout / show_block_cart.php ?
Regards,
Greg
Please Log in or Create an account to join the conversation.
7 years 1 month ago #310966
by nicolas
Replied by nicolas on topic characteristics variants (values) translation
Hi,
That's a good point.
Add the code:
before the code:
in the file administrator/components/com_hikashop/classes/product.php and let us know how it goes so that we can add the change on our end too.
That's a good point.
Add the code:
Code:
if(strpos($val->characteristic_value, '<') === false)
$val->characteristic_value = hikashop_translate($val->characteristic_value);
Code:
$variant->characteristics_text .= $separator . $val->characteristic_value;
The following user(s) said Thank You: Greg_C
Please Log in or Create an account to join the conversation.
7 years 1 month ago #310998
by Greg_C
Replied by Greg_C on topic characteristics variants (values) translation
Hi Nicolas, it works - thank you very much !
Regards,
Greg
Regards,
Greg
The following user(s) said Thank You: nicolas
Please Log in or Create an account to join the conversation.
Time to create page: 0.054 seconds