0

how can I specify the language of my website in HTML? I read that you can either use a meta tag or specify inside the <html> tag, which one is better? If there is any other way, please specify it.

Mr Lister
  • 45,515
  • 15
  • 108
  • 150
Jace Lee
  • 49
  • 8
  • Possible duplicate of [What's the difference between the lang attribute and the tag?](http://stackoverflow.com/questions/4436541/whats-the-difference-between-the-lang-attribute-and-the-meta-http-equiv-conte) – Gerald Schneider Dec 01 '15 at 13:57

1 Answers1

2

You would use the lang= attribute on the <html> element.

Madara's Ghost
  • 172,118
  • 50
  • 264
  • 308
  • 1
    @JaceLee: https://stackoverflow.com/questions/4436541/whats-the-difference-between-the-lang-attribute-and-the-meta-http-equiv-conte – Madara's Ghost Nov 24 '15 at 00:34
  • So let me get this straight, the `lang=` in the `` is to say what language the page is written in, the `` is for saying what the language is going to be output as? – Jace Lee Nov 24 '15 at 01:04
  • Nevermind that, seems that the `meta` is obsolete, so I'll use `` for now, until something goes wrong. Thanks – Jace Lee Nov 24 '15 at 01:24
  • Instead of using the tag, is it possible to add a line of code into the .htaccess file for that? – Jace Lee Nov 24 '15 at 01:32