- Posts: 2
- Thank you received: 0
notrans not work for canonical
2 years 10 months ago #357840
by Ebrahim
notrans not work for canonical was created by Ebrahim
-- HikaShop version -- : 5.0.2
-- Joomla version -- : 4.4.1
-- PHP version -- : 8.2.13
Hello, after updating to version 5.0.2, categories are translated twice by Canonical.
Therefore, if "#notrans#" is used, the "#notrans#" tag is removed in the first translation, and in the second translation, the phrase is translated.
First:
views/category/view.html.php
Second:
views/category/tmpl/listing.php
-- Joomla version -- : 4.4.1
-- PHP version -- : 8.2.13
Hello, after updating to version 5.0.2, categories are translated twice by Canonical.
Therefore, if "#notrans#" is used, the "#notrans#" tag is removed in the first translation, and in the second translation, the phrase is translated.
First:
views/category/view.html.php
Code:
$element->category_canonical = hikashop_translate($element->category_canonical);
Second:
views/category/tmpl/listing.php
Code:
$canonicalUrl = hikashop_cleanURL(hikashop_translate($this->element->category_canonical));
Please Log in or Create an account to join the conversation.
2 years 10 months ago #357844
by nicolas
Replied by nicolas on topic notrans not work for canonical
Hi,
Thanks for your feedback.
This change was made following an issue we fixed here:
www.hikashop.com/forum/product-category-...l-urls.html?start=20
However, we over corrected for the categories listing as we made it consistant with the product view.
So, to keep the consistency with product / listing, we'll be replacing the line:
$canonicalUrl = hikashop_cleanURL(hikashop_translate($this->element->category_canonical));
to:
$canonicalUrl = hikashop_cleanURL($this->element->category_canonical);
in views/category/tmpl/listing.php for the next release.
Thanks for your feedback.
This change was made following an issue we fixed here:
www.hikashop.com/forum/product-category-...l-urls.html?start=20
However, we over corrected for the categories listing as we made it consistant with the product view.
So, to keep the consistency with product / listing, we'll be replacing the line:
$canonicalUrl = hikashop_cleanURL(hikashop_translate($this->element->category_canonical));
to:
$canonicalUrl = hikashop_cleanURL($this->element->category_canonical);
in views/category/tmpl/listing.php for the next release.
The following user(s) said Thank You: Ebrahim
Please Log in or Create an account to join the conversation.
Time to create page: 0.043 seconds