Meta language not working? Meta language not working?
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

Meta language not working?

Started by Walkinman, December 31, 2013, 06:33:44 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Walkinman

hey Folks

I see on my site this code

<html dir="ltr">

instead of the "en-US" or whatever. This is called dynamically, I'm guessing, and something in my site isn't calling it correctly. I'm using a hacked up version of water_drop theme. My site is www.skolaiimages.com and the CPG stuff is in the directory /stock/
Example

/stock/thumbnails-122-Polar-Bear-Photos.html

I guess I can change it in template, but I thought it is supposed to be called dynamically, no? The template.html file says
<html dir="{LANG_DIR}">

Thanks

Cheers

Carl

Αndré

What exactly isn't working as expected? Information regarding the dir attribute: http://www.w3schools.com/tags/att_global_dir.asp

Walkinman

hey André

Oh . you're right .. I'm seeing an error on Bing's webmaster's tools that indicates somewhere the page should say something like

lang="en-US"

And that is not appearing in my cpg pages. I might be looking in the wrong place above, but that's the part that seems to be missing. I've no idea how critical it is, but Bing seems to mark it as moderately important.

Is that not right?

I can put that in manually, I suppose, but I thought cpg would probably call it dynamically depending on the user IP, no?

Walkinman

PS: if it helps better to explain what I'm talking about, this is the message I get from Bing's tools


The page is missing meta language information.

Recommended Action:
Use
<meta http-equiv="content-language" content="ll-cc"> tag in the <head> section of your page, where "ll-cc" stands for the culture code of the language and country/region the content applies to. Alternatively use the lang="ll-cc" attribute on either the <html> or the <title> tag.

SEO Explanation:
The Meta Language information is used as a hint to help us understand the intended language and country/region the page content applies to. This can help if your site is not hosted in the country/region. Use the "content-language" meta tag to embed the culture code in the <head> section of your page. For example,
<meta http-equiv="content-language" content="en-gb"> indicates that the page is in English and intended for the the United Kingdom. Alternatively, you can use <html lang="en-gb"> or <title lang="en-gb">
Thanks

Carl

Αndré

If you need that meta tag for SEO reasons, you'd need to add it yourself. Either hard-coded in your theme or dynamically. The country code ("cc" part) is available via $lang_translation_info['lang_country_code'], the language part may be available in the database (have a look at the fields "flag" and "abbr", unfortunately it seems to be incomplete).

Walkinman

Hey André

Ahh, thanks. I just coded it manually then,so it'll show <lang="en-US">. I'm not too sure it's a huge deal at all, just seeing what Bing points out on my site.

Thanks again.

Cheers

Carl