mirror of
https://github.com/wallabag/wallabag.git
synced 2024-12-16 18:30:17 +01:00
Add lang attribute in html tag
This commit is contained in:
parent
10ab20d8e2
commit
1b2abab6dd
@ -248,4 +248,9 @@ class Tools
|
||||
fclose($fp);
|
||||
}
|
||||
}
|
||||
|
||||
public static function getDocLanguage($userlanguage) {
|
||||
$lang = explode('.', $userlanguage);
|
||||
return str_replace('_', '-', $lang[0]);
|
||||
}
|
||||
}
|
@ -50,6 +50,7 @@ elseif (isset($_GET['plainurl']) && !empty($_GET['plainurl'])) {
|
||||
|
||||
# vars to send to templates
|
||||
$tpl_vars = array(
|
||||
'lang' => Tools::getDocLanguage($poche->user->getConfigValue('language')),
|
||||
'referer' => $referer,
|
||||
'view' => $view,
|
||||
'poche_url' => Tools::getPocheUrl(),
|
||||
|
@ -4,6 +4,7 @@
|
||||
<!--[if IE 8]><html class="no-js ie8 ie678" lang="en"><![endif]-->
|
||||
<!--[if gt IE 8]><html class="no-js" lang="en"><![endif]-->
|
||||
<html>
|
||||
<html lang="{{ lang }}">
|
||||
<head>
|
||||
<meta name="viewport" content="initial-scale=1.0">
|
||||
<meta charset="utf-8">
|
||||
|
Loading…
Reference in New Issue
Block a user