Reputation: 487
Is it ok to overlap lang attribute like below?
<div lang='ko'>
<div lang='en'>
Hello!
</div/>
<div>
Some messages in Korean here.
</div>
</div>
What would the standard say about this?
Upvotes: 1
Views: 45
Reputation: 163538
Yes, this is acceptable.
https://www.w3.org/TR/html5/dom.html#attr-lang
If an element doesn't have an lang
attribute, it will use the parent element's language.
Upvotes: 1