Jump to content
Sign in to follow this  
SiteSniffer

HTTP_ACCEPT_LANGUAGE and metatags

Recommended Posts

I'm checking browser language by using substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2).Am I allowed to use it for defining metatags keywords or will Google have problems indexing? I'm trying to have differend languages in metatags.

Edited by SiteSniffer

Share this post


Link to post
Share on other sites
I'm checking browser language by using substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2).Am I allowed to use it for defining metatags keywords or will Google have problems indexing? I'm trying to have differend languages in metatags.
I'm confused, is your website actually localized? If so you could do:
header('Content-Language: lang, tags, here');

Share this post


Link to post
Share on other sites

I ment when my website detects Dutch (nl) browser headers I want the metatags keywords (in header) to be in Dutch. IE <META NAME="keywords" CONTENT="word1, word2, word3">.Does Google check for language and then index a website? If not my routine will be useless I think.

Share this post


Link to post
Share on other sites

If, at your site, you have a facility to switch languages, disregarding the value of the Accept-Language header, Google will index both your Dutch and... I'd assume English... pages. As suggested, you can output a Content-Language to explicitly tell Google that the content is in a certain language. I'd argue it's best to only send this header if the language was computed based on the Accept-Language header, but that's just a personal opinion.If you don't have such a facility, but want to switch your keywords... that would be a black hat SEO trick... I wouldn't be surprised if Google goes as far as to penalize you if it detects you.

Share this post


Link to post
Share on other sites

I see. I'm not taking any chances on pulling a black hat SEO trick so I'll stick with a mix of Dutch and English keywords in my header.Thank you for your reply.

Edited by SiteSniffer

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...