Question on how to set language meta tags.

Popular automatic website translation tool

Question on how to set language meta tags.

Postby nemmar » Fri Oct 21, 2011 11:14 pm

Is there a way to have the correct language meta tags set for each translated language page?

For example, my translated pages have this in the head tag: html lang="en-gb" xml:lang="en-gb"

Does this matter for SEO or for AdSense ads being relevant and in the same language as the translated pages?

The AdSense ads showing up on the translated pages are all in English instead of matching the translated language of the page. Is Google AdSense not able to detect the correct language of the translated page due to the language meta tag being English?
nemmar
 
Posts: 26
Joined: Thu Oct 06, 2011 3:16 am

Re: Question on how to set language meta tags.

Postby Edvard » Sat Oct 22, 2011 7:24 pm

Hi,

That tags don't matter at all. You can remove them from your template.
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: 4183
Joined: Mon Jun 28, 2010 1:54 pm
Location: Yerevan, Armenia

Re: Question on how to set language meta tags.

Postby nemmar » Sat Nov 05, 2011 7:54 am

Edvard,

I checked my Gtranslate links to see how they pages look since I've had it installed on my site for over a month. The navigation menu links and the meta tags are getting translated, but most of the articles are still in English. How come that's happening? How long does it normally take for the full pages to be translated and cached so they show up as completely translated when their indexed or clicked?

Could the problem be the en-gb language tag in the headers? I know you said the following line above the head tag in my Joomla site can be removed:
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-gb" lang="en-gb" >

But I don't know if removing that line of code will affect other aspects needed for the site. I read these two post on your forum and was wondering if it's better if I tried these solutions:
post4026.html#p4026

url-language-code-t320.html

Let me know what your advice is.
Thanks!!
nemmar
 
Posts: 26
Joined: Thu Oct 06, 2011 3:16 am

Re: Question on how to set language meta tags.

Postby Edvard » Sun Nov 06, 2011 9:13 pm

Please write the page URL which is not translated.

If you check the source of https://gtranslate.io you will see that there are no lang attributes for html tag.
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: 4183
Joined: Mon Jun 28, 2010 1:54 pm
Location: Yerevan, Armenia

Re: Question on how to set language meta tags.

Postby nemmar » Tue Nov 08, 2011 10:17 pm

Edvard,

The navigation menu links and the meta tags are getting translated, but most of the articles are still in English. How come that's happening? You can see this same issue is happening with most of the articles on the site.

In the source code of the pages the language ref is above the head tag at the top of the pages:
Code: Select all
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-gb" lang="en-gb" >
<head>

Let me know if my GTranslate settings need to be adjusted. GTranslate is probably installed perfectly since you installed it for me when I purchased the extension on October 5.
Thanks for any advice on fixing this!!
Last edited by nemmar on Sat Dec 31, 2011 6:30 am, edited 1 time in total.
nemmar
 
Posts: 26
Joined: Thu Oct 06, 2011 3:16 am

Re: Question on how to set language meta tags.

Postby Edvard » Wed Nov 09, 2011 4:26 pm

Try to use this instead in your .htaccess file
Code: Select all
# 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]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)/(.*)$ /gtranslate/translate.php?lang=$1&url=$2&force_translation=1 [L,QSA]
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)$ /gtranslate/translate.php?lang=$1&force_translation=1 [L,QSA]


It will force the non-translated parts of your page to forcefully translated.
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: 4183
Joined: Mon Jun 28, 2010 1:54 pm
Location: Yerevan, Armenia

Re: Question on how to set language meta tags.

Postby nemmar » Wed Nov 09, 2011 6:30 pm

Edvard,

Okay, I replaced the following code in the .htacess file with the code in your post reply:

Code: Select all
# 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]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)/(.*)$ /gtranslate/translate.php?lang=$1&url=$2&force_no_api=1 [L,QSA]
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)$ /gtranslate/translate.php?lang=$1&force_no_api=1 [L,QSA]


1) Can you tell me why this problem occurred of my article content not being translated after months of using GTranslate?

2) You installed the GTranslate on my site yourself. Can you tell me what went wrong and why your installation did NOT work for months?

3) How do I know that this change of replacing the .htaccess file GTranslate config will actually work and now all my site pages will be translated into each language - and not partial page translations like has happened for months?

My worry about your installation of GTranslate from months ago was about my site getting a Google duplicate content penalty. You can see from my posts months ago on this forum I was asking you why my site pages article text were not translating from English - which leads to duplicate content penalties for Google! You replied that the pages were going to translate correctly - but they didn't. So I need to know for sure that GTranslate is working and WILL CONTINUE to work correctly so I don't have to "babysit" the translations and check them periodically.

Let me know.
nemmar
 
Posts: 26
Joined: Thu Oct 06, 2011 3:16 am

Re: Question on how to set language meta tags.

Postby Edvard » Wed Nov 09, 2011 6:38 pm

The thing is that somewhere on your site you have some text which is not possible to translated to any language. When the parser comes to that text and it is not able to translate it it stops the further page translation, but if you add force_translation, it will keep on going.

The GTranslate Pro worked for your site and a lot of pages are indexed by Google. You can check that the titles and meta descriptions of your pages were translated and that is the most important thing for Google.

Just to be sure, check that currently you have this code in .htaccess file, seems that you also had force_no_api parameter.

Code: Select all
# 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]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)/(.*)$ /gtranslate/translate.php?lang=$1&url=$2&force_no_api=1&force_translation=1 [L,QSA]
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)$ /gtranslate/translate.php?lang=$1&force_no_api=1&force_translation=1 [L,QSA]


You cannot be penalized by Google, since it doesn't penalize you if you copy content from your own site.
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: 4183
Joined: Mon Jun 28, 2010 1:54 pm
Location: Yerevan, Armenia

Re: Question on how to set language meta tags.

Postby nemmar » Wed Nov 09, 2011 7:07 pm

Edvard,

Okay, now I'm really confused??? I copied the .htaccess code from your post in this thread that you posted today. Here is what I NOW have in my .htaccess file related to GTranslate (there are other lines after this in .htaccess but it's related to Joomla and were there when you installed GTranslate on my site):
Code: Select all
RewriteEngine On

# 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]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)/(.*)$ /gtranslate/translate.php?lang=$1&url=$2&force_translation=1 [L,QSA]
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)$ /gtranslate/translate.php?lang=$1&force_translation=1 [L,QSA


So the newest code in your latest post has something different, including the "force_no_api=1&force_translation" line. So do I need to replace the .htaccess code I have listed in this post, with the code you posted in your last reply with the "force_no_api=1&force_translation" line in it?

There is nothing unusual about the articles on my site. They are standard text articles pasted into the Joomla text editor and posted from the Joomla MySQL database. So if there's some abnormal text on my site that you're saying prevented translations, can you tell me where it is? Because most of the articles I checked were NOT being translated, just the menus and links were translated but NOT the article text. I don't have any custom code/scripting on my site so it's just a normal Joomla site. I don't know where this "mystery" text is located, but maybe you can find it and tell me where it is.

You cannot be penalized by Google, since it doesn't penalize you if you copy content from your own site.

Edvard, I appreciate you helping me resolve this issue since I think GTranslate could be a great program to get my site automatically translated and indexed into the 58 foreign languages. So if you can fix this issue I will be very happy and grateful for your help. I really don't want to take a chance and trust when you write "you can't be penalized by Google".
Last edited by nemmar on Wed Nov 16, 2011 7:31 am, edited 1 time in total.
nemmar
 
Posts: 26
Joined: Thu Oct 06, 2011 3:16 am

Re: Question on how to set language meta tags.

Postby nemmar » Wed Nov 09, 2011 11:19 pm

Edvard,

I added the last .htaccess code you posted into my .htaccess file:

Code: Select all
# 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]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)/(.*)$ /gtranslate/translate.php?lang=$1&url=$2&force_no_api=1&force_translation=1 [L,QSA]
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)$ /gtranslate/translate.php?lang=$1&force_no_api=1&force_translation=1 [L,QSA]


Can you tell me if this is the correct code (above)?
Or should I use the other .htaccess code (below) that you posted in a prior reply:

Code: Select all
# 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]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)/(.*)$ /gtranslate/translate.php?lang=$1&url=$2&force_translation=1 [L,QSA]
RewriteRule ^([a-z]{2}|zh-CN|zh-TW)$ /gtranslate/translate.php?lang=$1&force_translation=1 [L,QSA]


Let me know. Thanks.
nemmar
 
Posts: 26
Joined: Thu Oct 06, 2011 3:16 am

Re: Question on how to set language meta tags.

Postby Edvard » Thu Nov 10, 2011 4:04 pm

Above code is OK.

If you want to find the mystery text, you can turn on the debug mode and find it in the debug.txt file.

Let's just go on the well-known, well-established fact that Google does NOT want duplicate content URLs showing up in their search results.


You don't have 2 URLs which content is identical for 100% and I'm sure what I say.
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: 4183
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