Little Bug when using flag :P

Popular automatic website translation tool

Little Bug when using flag :P

Postby d.hingorani86 » Fri Sep 12, 2014 11:40 pm

Hello,

We just noticed increase in 404 errors on using Brazilian flag

http://www.domain.com/da/3911Page.php
http://www.domain.com/it/3922Page.php
http://www.domain.com/ar/3933Page.php
http://www.domain.com/da/pt/3944Page.php <---- ?? (Brazalian flag) 404 Not Found Error.

We have corrected this by using Portuguese flag but now we need to correct 10,000 404 Error links in Google by creating a forwarded in htaccess like below:

RewriteCond %{HTTP_HOST} "domain.com/da/pt/XXXXPage.php"$
RewriteRule ^(.*)$ http://www.domain.com/pt/XXXXPage.php [R=301,L]

RewriteCond %{HTTP_HOST} "domain.com/it/pt/XXXXPage.php"$
RewriteRule ^(.*)$ http://www.domain.com/pt/XXXXPage.php [R=301,L]

Please provide correct lines to be included in htaccess to convert
"domain.com/it/pt/XX" ---> "domain.com/pt/XX"

Your suggestions and help will be highly appreciated.

Regards,
Danish.
d.hingorani86
 
Posts: 14
Joined: Wed Aug 13, 2014 9:14 am

Re: Little Bug when using flag :P

Postby Edvard » Fri Sep 12, 2014 11:56 pm

Please use this rules:

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]
Regards,

Edvard Ananyan - GTranslate Team

Please leave your feedback on your CMS plugin directory. It is very important for us!
Google Translate Joomla
Google Translate WordPress
Google Translate Drupal
Edvard
Site Admin
 
Posts: 4185
Joined: Mon Jun 28, 2010 1:54 pm
Location: Yerevan, Armenia

Re: Little Bug when using flag :P

Postby d.hingorani86 » Sat Sep 13, 2014 9:26 pm

This is wrong.

I am getting

"domain.com/it/pt/XX" ---> "domain.com/it/XX"

I want:

"domain.com/it/pt/XX" ---> "domain.com/pt/XX"

Please help.
d.hingorani86
 
Posts: 14
Joined: Wed Aug 13, 2014 9:14 am

Re: Little Bug when using flag :P

Postby Edvard » Sat Sep 13, 2014 9:30 pm

Replace $1 with $2.
Regards,

Edvard Ananyan - GTranslate Team

Please leave your feedback on your CMS plugin directory. It is very important for us!
Google Translate Joomla
Google Translate WordPress
Google Translate Drupal
Edvard
Site Admin
 
Posts: 4185
Joined: Mon Jun 28, 2010 1:54 pm
Location: Yerevan, Armenia


  • Related Topics
    Replies
    Views
    Last post

Who is online

Users browsing this forum: No registered users and 0 guests

2GLux