Skip to content

Commit

Permalink
html lang
Browse files Browse the repository at this point in the history
  • Loading branch information
Gutza committed Feb 15, 2014
1 parent 5ce7f80 commit 5c68c50
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions include/classes/LPC_HTML_document.php
Expand Up @@ -68,6 +68,11 @@ public function show($once = false)

public function render($indent=0)
{
$lang = LPC_Language::getCurrent();
$POSIX = $lang->getAttr("locale_POSIX");
if (strlen($POSIX) > 1) // at least 2
$this->setAttr("lang", substr($POSIX, 0, 2));

$this->prepareContent($this->content);
if ($this->doctype & LPC_HTML_doctype::type_XHTML1)
$this->setAttr("xmlns","http://www.w3.org/1999/xhtml");
Expand Down

0 comments on commit 5c68c50

Please sign in to comment.