The Joomla! Forum ™






Post new topic Reply to topic  [ 30 posts ] 
Author Message
PostPosted: Wed Jan 16, 2008 4:36 pm 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Tue Dec 12, 2006 8:37 pm
Posts: 119
I've been looking for a solution allowing creation/saving of article aliases having non-ASCII-7 characters.

Currently all non-ASCII-7 characters are being cleaned-up by transliterate() and stringURLSafe() functions.

As far as I understood, having non-ANCII letters in the URL will not create problems for SEF engine and the article could be opened. I'm I right? If yes, how could I acooplish the task?

Thanks.

_________________
www.justPHP.net - HACKS for Hot Property, Custom 404 Error Pages, Templates for Joomla etc.
Developing: www.zerno.org.ua


Top
 Profile  
 
PostPosted: Wed Jan 16, 2008 5:48 pm 
User avatar
Joomla! Master
Joomla! Master

Joined: Fri Aug 12, 2005 3:47 pm
Posts: 16630
Location: **Translation Matters**
No way to do this anymore with Joomla.
Any url with utf8 glyphs is translated (also with simple latin-1).
If you don't, you get that kind:
http://zh.wikipedia.org/w/index.php?tit ... iant=zh-tw

and it gets very looooooooong when one is getting to a category item with a very long title

To use Ascii 7 is a simple and secure solution.

Note: to get the older behaviour means a lot of changes in core.

_________________
Jean-Marie Simonet / infograf · http://www.info-graf.fr
Multilanguage in 2.5: http://help.joomla.org/files/EN-GB_multilang_tutorial.pdf
---------------------------------
Joomla Translation Coordination Team • Joomla! Production Working Group


Last edited by infograf768 on Wed Jan 16, 2008 5:50 pm, edited 1 time in total.

Top
 Profile  
 
PostPosted: Wed Jan 16, 2008 6:04 pm 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Tue Dec 12, 2006 8:37 pm
Posts: 119
Thanks for the reply. Not good news, of cause... 

Even if I convert the title from UTF-8 into ISO-8859-5 and try to make the alias - it will not help?

Also, if you could provide more info/links about the question, I'll appreciate it very much. I'll help me to study the quesion in details, as technically it seems to be possible (http://ru.wikipedia.org/wiki/Кодировка this page is in UTF-8 encoding).

_________________
www.justPHP.net - HACKS for Hot Property, Custom 404 Error Pages, Templates for Joomla etc.
Developing: www.zerno.org.ua


Top
 Profile  
 
PostPosted: Wed Jan 16, 2008 6:15 pm 
User avatar
Joomla! Master
Joomla! Master

Joined: Fri Aug 12, 2005 3:47 pm
Posts: 16630
Location: **Translation Matters**
http://ru.wikipedia.org/wiki/%D0%9A%D0% ... 0%BA%D0%B0 is the real slug.

_________________
Jean-Marie Simonet / infograf · http://www.info-graf.fr
Multilanguage in 2.5: http://help.joomla.org/files/EN-GB_multilang_tutorial.pdf
---------------------------------
Joomla Translation Coordination Team • Joomla! Production Working Group


Top
 Profile  
 
PostPosted: Thu Jan 17, 2008 10:55 am 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Tue Dec 12, 2006 8:37 pm
Posts: 119
Hm... It seems that only translit (http://translit.us/) could be used in the URLs.
As far as I understood some of the "non-ASCII" search engines take into cosideration of the URLs as they can decode them back into original language.

Thanks, infograf768.

_________________
www.justPHP.net - HACKS for Hot Property, Custom 404 Error Pages, Templates for Joomla etc.
Developing: www.zerno.org.ua


Top
 Profile  
 
PostPosted: Thu Jan 17, 2008 1:43 pm 
User avatar
Joomla! Master
Joomla! Master

Joined: Fri Aug 12, 2005 3:47 pm
Posts: 16630
Location: **Translation Matters**
np

_________________
Jean-Marie Simonet / infograf · http://www.info-graf.fr
Multilanguage in 2.5: http://help.joomla.org/files/EN-GB_multilang_tutorial.pdf
---------------------------------
Joomla Translation Coordination Team • Joomla! Production Working Group


Top
 Profile  
 
PostPosted: Wed Oct 22, 2008 11:44 am 
Joomla! Apprentice
Joomla! Apprentice

Joined: Wed Oct 22, 2008 11:36 am
Posts: 9
grayz wrote:
I've been looking for a solution allowing creation/saving of article aliases having non-ASCII-7 characters.

Currently all non-ASCII-7 characters are being cleaned-up by transliterate() and stringURLSafe() functions.

As far as I understood, having non-ANCII letters in the URL will not create problems for SEF engine and the article could be opened. I'm I right? If yes, how could I acooplish the task?

Thanks.


hi,
which page the title converting alias. i mean where the transliterate() and stringURLSafe() functions used. i wanna add a alias code before them but i couldnt find them.


Top
 Profile  
 
PostPosted: Wed Oct 22, 2008 3:34 pm 
User avatar
Joomla! Master
Joomla! Master

Joined: Fri Aug 12, 2005 3:47 pm
Posts: 16630
Location: **Translation Matters**
libraries/joomla/language/language.php

and

libraries/joomla/filter/filteroutput.php

_________________
Jean-Marie Simonet / infograf · http://www.info-graf.fr
Multilanguage in 2.5: http://help.joomla.org/files/EN-GB_multilang_tutorial.pdf
---------------------------------
Joomla Translation Coordination Team • Joomla! Production Working Group


Top
 Profile  
 
PostPosted: Wed Oct 22, 2008 6:34 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Wed Oct 22, 2008 11:36 am
Posts: 9
infograf768 wrote:
libraries/joomla/language/language.php

and

libraries/joomla/filter/filteroutput.php


i made it. thank you very very much...


Top
 Profile  
 
PostPosted: Thu Oct 23, 2008 6:10 am 
User avatar
Joomla! Master
Joomla! Master

Joined: Fri Aug 12, 2005 3:47 pm
Posts: 16630
Location: **Translation Matters**
Out of pure curiosity, what did you change in order to get what?

_________________
Jean-Marie Simonet / infograf · http://www.info-graf.fr
Multilanguage in 2.5: http://help.joomla.org/files/EN-GB_multilang_tutorial.pdf
---------------------------------
Joomla Translation Coordination Team • Joomla! Production Working Group


Top
 Profile  
 
PostPosted: Thu Oct 23, 2008 8:24 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Wed Oct 22, 2008 11:36 am
Posts: 9
infograf768 wrote:
Out of pure curiosity, what did you change in order to get what?


i added replace codes for some Non ASCII-7 Turkish characters which joomla cant convert them latin correctly. now the titles which contain Non ASCII-7 characters converted to alias automatically.


Top
 Profile  
 
PostPosted: Fri Oct 24, 2008 4:15 am 
User avatar
Joomla! Master
Joomla! Master

Joined: Fri Aug 12, 2005 3:47 pm
Posts: 16630
Location: **Translation Matters**
Could you share more?
What are the Turkish non-latin characters involved and the code you added or changed in the 2 files?

_________________
Jean-Marie Simonet / infograf · http://www.info-graf.fr
Multilanguage in 2.5: http://help.joomla.org/files/EN-GB_multilang_tutorial.pdf
---------------------------------
Joomla Translation Coordination Team • Joomla! Production Working Group


Top
 Profile  
 
PostPosted: Fri Oct 24, 2008 11:13 am 
Joomla! Apprentice
Joomla! Apprentice

Joined: Wed Oct 22, 2008 11:36 am
Posts: 9
infograf768 wrote:
Could you share more?
What are the Turkish non-latin characters involved and the code you added or changed in the 2 files?


sorry my fault...

the characters are : ş ı ü ö ğ ç

i added the code in transliterate() function at libraries/joomla/language/language.php file (i do not made any change at libraries/joomla/filter/filteroutput.php)

her is the code i added:
Code:
      $string = JString::strtolower($string);
      $tr = array('ğ','ü','ş','ö','ç', 'ı');
      $en = array('g','u','s','o','c', 'i');
      $string = JString::str_ireplace($tr, $en, $string);


so, the string converted to ASCII-7 characters first and then converted to alias correctly. (i saved the file utf-8 format).


Top
 Profile  
 
PostPosted: Sat Jul 25, 2009 9:28 pm 
User avatar
Joomla! Apprentice
Joomla! Apprentice

Joined: Sat Sep 29, 2007 5:41 pm
Posts: 26
Location: Türkiye
thanks i need this


Top
 Profile  
 
PostPosted: Fri Oct 23, 2009 9:24 am 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Wed Mar 25, 2009 8:08 am
Posts: 146
Location: Europe
What's the verdict on this? Is this a good solution? Has this been fixed in a newer version off Joomla? All I can find is, is that a solution is planned for 1.6.


Top
 Profile  
 
PostPosted: Fri Oct 23, 2009 10:17 am 
User avatar
Joomla! Master
Joomla! Master

Joined: Fri Aug 12, 2005 3:47 pm
Posts: 16630
Location: **Translation Matters**
The solution is implemented in 1.6.
Plugins are available for 1.5.

_________________
Jean-Marie Simonet / infograf · http://www.info-graf.fr
Multilanguage in 2.5: http://help.joomla.org/files/EN-GB_multilang_tutorial.pdf
---------------------------------
Joomla Translation Coordination Team • Joomla! Production Working Group


Top
 Profile  
 
PostPosted: Fri Oct 23, 2009 10:31 am 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Wed Mar 25, 2009 8:08 am
Posts: 146
Location: Europe
Thanks for the fast reply.

With the risk off asking something I might find myself....
I looked into the plugins, but I couldn't find 1 that could accomplish what I'm looking for. I found 1 that came close: http://extensions.joomla.org/extensions ... t/sef/7132 but that doesn't support the Turkish language.


Top
 Profile  
 
PostPosted: Fri Oct 23, 2009 3:19 pm 
User avatar
Joomla! Master
Joomla! Master

Joined: Fri Aug 12, 2005 3:47 pm
Posts: 16630
Location: **Translation Matters**
glimbeek wrote:
Thanks for the fast reply.

With the risk off asking something I might find myself....
I looked into the plugins, but I couldn't find 1 that could accomplish what I'm looking for. I found 1 that came close: http://extensions.joomla.org/extensions ... t/sef/7132 but that doesn't support the Turkish language.

This one should do.
It can be customized for any language.
Attachment:
plgTurkceAlias12.txt

Change suffix .txt to .zip to install.


You do not have the required permissions to view the files attached to this post.

_________________
Jean-Marie Simonet / infograf · http://www.info-graf.fr
Multilanguage in 2.5: http://help.joomla.org/files/EN-GB_multilang_tutorial.pdf
---------------------------------
Joomla Translation Coordination Team • Joomla! Production Working Group


Top
 Profile  
 
PostPosted: Tue Oct 27, 2009 7:43 am 
User avatar
Joomla! Apprentice
Joomla! Apprentice

Joined: Sat Sep 29, 2007 5:41 pm
Posts: 26
Location: Türkiye
i konw im used more ago thanks


Top
 Profile  
 
PostPosted: Tue Oct 27, 2009 7:53 am 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Wed Mar 25, 2009 8:08 am
Posts: 146
Location: Europe
So what does this plugin do? My site has a fair few language that use "odd" characters, can I be sure that nothing will change and that it will only "function" for the Turkish language?

Do I need to use/install something else to make this work? Like a Turkish front-end language?


Top
 Profile  
 
PostPosted: Tue Oct 27, 2009 9:19 am 
User avatar
Joomla! Master
Joomla! Master

Joined: Fri Aug 12, 2005 3:47 pm
Posts: 16630
Location: **Translation Matters**
This plugin just adds plain transliteration for some Latin Extended-A characters out of the box when you create a new article. It does not modify existing aliases, nor does it forces you to do anyhting as you can control the alias.

_________________
Jean-Marie Simonet / infograf · http://www.info-graf.fr
Multilanguage in 2.5: http://help.joomla.org/files/EN-GB_multilang_tutorial.pdf
---------------------------------
Joomla Translation Coordination Team • Joomla! Production Working Group


Top
 Profile  
 
PostPosted: Tue Oct 27, 2009 12:45 pm 
Joomla! Enthusiast
Joomla! Enthusiast

Joined: Wed Mar 25, 2009 8:08 am
Posts: 146
Location: Europe
Thank you for your great support infograf768, I installed the plugin and tested it and it seems to be working.


Top
 Profile  
 
PostPosted: Tue Oct 27, 2009 2:08 pm 
User avatar
Joomla! Master
Joomla! Master

Joined: Fri Aug 12, 2005 3:47 pm
Posts: 16630
Location: **Translation Matters**
In fact, folks, some people WANT utf8 in the slugs.
I have provided a plugin to just do that.

http://extensions.joomla.org/extensions ... /sef/10275

Enjoy!

_________________
Jean-Marie Simonet / infograf · http://www.info-graf.fr
Multilanguage in 2.5: http://help.joomla.org/files/EN-GB_multilang_tutorial.pdf
---------------------------------
Joomla Translation Coordination Team • Joomla! Production Working Group


Top
 Profile  
 
PostPosted: Mon Apr 26, 2010 12:53 pm 
Joomla! Fledgling
Joomla! Fledgling

Joined: Mon Apr 26, 2010 12:47 pm
Posts: 1
this code doesnt works or something wrong...


Top
 Profile  
 
PostPosted: Sun Jan 02, 2011 8:43 am 
Joomla! Apprentice
Joomla! Apprentice

Joined: Tue Nov 18, 2008 5:47 pm
Posts: 6
gerilla thank you very much for this useful lang modification.
I use it for my native language
you save a lot of time


Top
 Profile  
 
PostPosted: Sat Jul 16, 2011 9:41 am 
User avatar
Joomla! Intern
Joomla! Intern

Joined: Fri Nov 17, 2006 12:20 pm
Posts: 87
I know this is an old thread, but still, someone could find this useful.
I've did the same thing for Serbian language (which also had problems converting accented letters).
The code is completely the same as for the Turkish letters, only file names are changed (to reflect the usage) and of course, the accented letters themselves (š, đ, č, ć, ž) => (s, dj, c, c, z).


You do not have the required permissions to view the files attached to this post.

_________________
http://www.gusari.org


Top
 Profile  
 
PostPosted: Thu Sep 01, 2011 1:17 am 
Joomla! Fledgling
Joomla! Fledgling

Joined: Thu Sep 01, 2011 1:10 am
Posts: 1
Found this forum very useful. Thanks everybody.
thanks,
Tino


Top
 Profile  
 
PostPosted: Thu Sep 01, 2011 5:24 am 
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Aug 29, 2011 12:55 pm
Posts: 20
i have a question about it
is it usefull for seo ?

_________________
http://www.dr-shadabi.ir
http://www.zarvansaffron.ir


Top
 Profile  
 
PostPosted: Fri Mar 09, 2012 11:09 am 
Joomla! Fledgling
Joomla! Fledgling

Joined: Fri Mar 09, 2012 9:42 am
Posts: 1
Hi all!
I tried to make the same thing for Hungarian language but this plugin (as the original -turkish- one) broke the whole site (backend & frontend).
Joomla! 2.5.0 Stable

Any ideas?

thanks
-bbb-


Top
 Profile  
 
PostPosted: Fri Mar 09, 2012 3:59 pm 
User avatar
Joomla! Master
Joomla! Master

Joined: Fri Aug 12, 2005 3:47 pm
Posts: 16630
Location: **Translation Matters**
bbb16 wrote:
Hi all!
I tried to make the same thing for Hungarian language but this plugin (as the original -turkish- one) broke the whole site (backend & frontend).
Joomla! 2.5.0 Stable

Any ideas?

thanks
-bbb-

2.5 is totally different.

There is a default transliterate file which does transliterate Turkish as well as Hungarian characters.
If someone wants only specific ascii aliases, a function has to be added in the xx-XX.localise.php of the language folder.

These plugins are useless in 2.5.

If you have a question concerning 2.5, please post in 2.5 forums.

_________________
Jean-Marie Simonet / infograf · http://www.info-graf.fr
Multilanguage in 2.5: http://help.joomla.org/files/EN-GB_multilang_tutorial.pdf
---------------------------------
Joomla Translation Coordination Team • Joomla! Production Working Group


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 30 posts ] 



Who is online

Users browsing this forum: No registered users and 12 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group