Dofactory.com
Dofactory.com
Earn income with your HTML skills
Sign up and we'll send you the best freelance opportunities straight to your inbox.
We're building the largest freelancing marketplace for people like you.
By adding your name & email you agree to our terms, privacy and cookie policies.

HTML <textarea> lang Attribute

The lang attribute on an <textarea> tag specifies the language of the textarea.

Its value is used for site accessibility, translations, and SEO purposes.

Example

#

A lang attribute on a <textarea> element.
This textarea uses a different language.

<textarea lang="el" rows="5" cols="45">
Η Ακρόπολη της Αθήνας είναι μια 
αρχαία ακρόπολη που βρίσκεται σε 
ένα βραχώδες λιβάδι πάνω από την 
πόλη της Αθήνας και περιέχει τα 
ερείπια πολλών αρχαίων κτιρίων 
μεγάλης αρχιτεκτονικής και 
ιστορικής σημασίας, με το πιο 
διάσημο να είναι ο Παρθενώνας.
</textarea>

Using lang

The lang attribute specifies the language used in the texterea.

The first two characters of the lang value refers to the language code.

The last two characters - which are optional - refer to the country code.


Syntax

<textarea lang="language-code-country-code">

Values

#

Value Description
language-code-country-code The first 2 characters represent the language code of the page.
The last two characters represent the country code (optional).

Browser support

Here is when lang support started for each browser:

Chrome
1.0 Sep 2008
Firefox
1.0 Sep 2002
IE/Edge
1.0 Aug 1995
Opera
1.0 Jan 2006
Safari
1.0 Jan 2003

You may also like

 Back to <textarea>

Last updated on Sep 30, 2023

Earn income with your HTML skills
Sign up and we'll send you the best freelance opportunities straight to your inbox.
We're building the largest freelancing marketplace for people like you.
By adding your name & email you agree to our terms, privacy and cookie policies.

Guides