Stop “language_attributes” producing invalid XHTML 1.1?
-
I’m trying to make an XHTML 1.1 theme. I’m using the “language_attributes” function in the header, as recommended.
<html xmlns="https://www.w3.org/1999/xhtml" <?php language_attributes('xhtml'); ?>>
However, this produces the following.
<html xmlns="https://www.w3.org/1999/xhtml" dir="ltr" lang="en-US" xml:lang="en-US">
“lang” is invalid markup in XHTML 1.1 – only “xml:lang” is allowed.
Is there anyway of having WordPress return the correct attributes? I could modify the language_attributes function to be able to take an “xhtml 1.1” attribute, but I’d prefer not to mod the WordPress code, as it’s a pain when updating.
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘Stop “language_attributes” producing invalid XHTML 1.1?’ is closed to new replies.