Subdirectory Translations
Jan 5, 2011 11:54 am by [email protected]
Jan 5, 2011 11:54 am by [email protected]
Hi,
I am having very strange problem..... Google has pickup the followin URL's
/sw/el/page-1.html
/sw/el/page-2.html
/sw/el/page-3.html
etc.
I mean I dont want the subdirectory "el" of "sw"to be shown because it causes double metatags in Webmaster Tools.
Why this is happening and what can I do about it?
Re: Subdirectory Translations
Feb 8, 2011 10:52 am by Edvard
Feb 8, 2011 10:52 am by Edvard
Hi,
Please use this rewrite rules instead of the old ones:
# gtranslate config
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)/([a-z]{2}|zh-CN|zh-TW)/(.*)$ /$1/$3 [R=301,L]
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)/([a-z]{2}|zh-CN|zh-TW)$ /$1/ [R=301,L]
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)/(.*)$ /gtranslate/translate.php?lang=$1&url=$2 [L,QSA]
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)$ /gtranslate/translate.php?lang=$1 [L,QSA]
This will prevent the indexing of double language codes, and if you access for example: /sw/el/page-1.html you will end up on /sw/page-1.html
SIMILAR TOPICS
Export all custom translations | Jul 5, 2018 11:50 am | Replies: 1 | Post by: sadashiv |
Limited custom translations? | Feb 13, 2018 10:35 am | Replies: 3 | Post by: natmatsci |
Some of the translations on my site are not correct | Nov 13, 2017 9:33 am | Replies: 5 | Post by: straightpoint |
Translations lost and reverted to wrong version. | Dec 6, 2016 4:07 pm | Replies: 5 | Post by: sadashiv |
Joomla root is in our /en/ subdirectory (will that work?) | Mar 5, 2017 3:24 am | Replies: 1 | Post by: Rik Brown |