- Posts: 1
- Thank you received: 1
Incorrect display Unicode in SEF url
- ebrahimiali
-
Topic Author
- Offline
Less
More
10 years 10 months ago - 10 years 10 months ago #222899
by ebrahimiali
Incorrect display Unicode in SEF url was created by ebrahimiali
-- HikaShop version -- : 2.6.0
-- Joomla version -- : 3.4.5
-- PHP version -- : 5.5
-- Browser(s) name and version -- : chrome
-- Error-message(debug-mod must be tuned on) -- : Incorrect display Unicode in SEF url
I've found 3 errors for Unicode languages.
in :
Create Metakeyword unicode :
file : back\helpers\seo.php
line 44
old :
best :
=====================================
Create MetaDescription:
file : back\helpers\seo.php
line26
old :
best :
=====================================
Create UTF8 SEF url:
file : back\classes\product.php
Old :
Best :
=====================================
Create UTF8 SEF url:
file : back\classes\category.php
old :
best:
=====================================
Create UTF8 SEF url:
file : back\classes\cart.php
old :
best:
-- Joomla version -- : 3.4.5
-- PHP version -- : 5.5
-- Browser(s) name and version -- : chrome
-- Error-message(debug-mod must be tuned on) -- : Incorrect display Unicode in SEF url
I've found 3 errors for Unicode languages.
in :
Create Metakeyword unicode :
file : back\helpers\seo.php
line 44
old :
Code:
if(strlen($word)<3){
Code:
if(mb_strlen($word)<3){
=====================================
Create MetaDescription:
file : back\helpers\seo.php
line26
old :
Code:
$meta = substr($this->clean($element->$description),0,$max);
Code:
$meta = mb_substr($this->clean($element->$description),0,$max);
=====================================
Create UTF8 SEF url:
file : back\classes\product.php
Old :
Code:
if(method_exists($app,'stringURLSafe')){
$element->alias = $app->stringURLSafe($element->alias);
}else{
$element->alias = JFilterOutput::stringURLSafe($element->alias);
}
Code:
if(method_exists($app,'stringURLSafe')){
$element->alias = $app->stringURLSafe($element->alias);
}else{
$element->alias = JFilterOutput::stringURLUnicodeSlug($element->alias);
}
=====================================
Create UTF8 SEF url:
file : back\classes\category.php
old :
Code:
$app = JFactory::getApplication();
if(method_exists($app,'stringURLSafe'))
$element->alias = $app->stringURLSafe(strip_tags($element->alias));
else
$element->alias = JFilterOutput::stringURLSafe(strip_tags($element->alias));
Code:
$app = JFactory::getApplication();
if(method_exists($app,'stringURLSafe'))
$element->alias = $app->stringURLSafe(strip_tags($element->alias));
else
$element->alias = JFilterOutput::stringURLUnicodeSlug(strip_tags($element->alias));
=====================================
Create UTF8 SEF url:
file : back\classes\cart.php
old :
Code:
if(method_exists($app,'stringURLSafe')){
$alias = $app->stringURLSafe($alias);
}else{
$alias = JFilterOutput::stringURLSafe($alias);
}
Code:
if(method_exists($app,'stringURLSafe')){
$alias = $app->stringURLSafe($alias);
}else{
$alias = JFilterOutput::stringURLUnicodeSlug($alias);
}
Last edit: 10 years 10 months ago by Jerome. Reason: [code] is nice
The following user(s) said Thank You: Jerome
Please Log in or Create an account to join the conversation.
10 years 10 months ago #222986
by nicolas
Replied by nicolas on topic Incorrect display Unicode in SEF url
Hi,
Thank you for sharing your modifications. We'll include them on our end for better UTF8 support in the URLs with the next version.
Thank you for sharing your modifications. We'll include them on our end for better UTF8 support in the URLs with the next version.
Please Log in or Create an account to join the conversation.
Time to create page: 0.144 seconds