mirror of
https://git.code.sf.net/p/seeddms/code
synced 2024-11-26 15:32:13 +00:00
use only first two chars of language in html lang attribute
This commit is contained in:
parent
6849ccd34d
commit
b65322ab54
|
@ -101,9 +101,11 @@ class SeedDMS_Theme_Style extends SeedDMS_View_Common {
|
|||
echo "<!DOCTYPE html>\n";
|
||||
echo "<html lang=\"";
|
||||
if(!empty($this->params['session']) && ($slang = $this->params['session']->getLanguage())) {
|
||||
echo str_replace('_', '-', $slang);
|
||||
echo substr($slang, 0, 2);
|
||||
// echo str_replace('_', '-', $slang);
|
||||
} else {
|
||||
echo str_replace('_', '-', $this->params['settings']->_language);
|
||||
echo substr($this->params['settings']->_language, 0, 2);
|
||||
// echo str_replace('_', '-', $this->params['settings']->_language);
|
||||
}
|
||||
echo "\">\n<head>\n";
|
||||
echo "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n";
|
||||
|
|
|
@ -103,9 +103,11 @@ class SeedDMS_Theme_Style extends SeedDMS_View_Common {
|
|||
echo "<!DOCTYPE html>\n";
|
||||
echo "<html lang=\"";
|
||||
if(!empty($this->params['session']) && ($slang = $this->params['session']->getLanguage())) {
|
||||
echo str_replace('_', '-', $slang);
|
||||
echo substr($slang, 0, 2);
|
||||
// echo str_replace('_', '-', $slang);
|
||||
} else {
|
||||
echo str_replace('_', '-', $this->params['settings']->_language);
|
||||
echo substr($this->params['settings']->_language, 0, 2);
|
||||
// echo str_replace('_', '-', $this->params['settings']->_language);
|
||||
}
|
||||
echo "\">\n<head>\n";
|
||||
echo "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n";
|
||||
|
|
Loading…
Reference in New Issue
Block a user