WebAIM - Web Accessibility In Mind

E-mail List Archives

Use of 'lang' attribute?

for

From: Joseph Sherman
Date: Nov 2, 2015 11:50AM


Is there any other use of the 'lang' attribute besides specifying language?
I am looking at a web application that uses the 'lang' attribute all over the place. Most all elements have 'lang', for example, here's a row of table headers:

<tr><th lang="isSelected" rowspan="1" colspan="undefined"><span class="headerText">Selected</span></th><th class="alt sortable" lang="employee" rowspan="1" colspan="undefined"><span class="headerText">Last / First</span></th><th class=" sortable" lang="payroll" rowspan="1" colspan="undefined"><span class="headerText">EMPL ID</span></th><th class="alt sortable" lang="totalHoursWorked" rowspan="1" colspan="undefined"><span class="headerText">Total Worked Hours</span></th><th class=" sortable" lang="totalPaidAbsences" rowspan="1" colspan="undefined"><span class="headerText">Total Paid Absences</span></th>

Even the login form password field has it: <td class="localize" lang="password">Password</td>

Is there any reason for this? Can it confuse a screen reader or is it harmless?

Joseph