From 7ecfbd69130a6135f4edf9f7df7063bffa6c287a Mon Sep 17 00:00:00 2001 From: shimingxy Date: Sun, 21 Jun 2020 22:54:52 +0800 Subject: [PATCH] Update head.html --- docs/_includes/head.html | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/docs/_includes/head.html b/docs/_includes/head.html index 0d500054..618534c1 100644 --- a/docs/_includes/head.html +++ b/docs/_includes/head.html @@ -27,6 +27,12 @@ var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(hm, s); })(); + + currentLang = navigator.language; //判断除IE外其他浏览器使用语言 + if(!currentLang){//判断IE浏览器使用语言 + currentLang = navigator.browserLanguage; + } + alert(currentLang);