Browse Source

Update head.html

shimingxy 4 năm trước cách đây
mục cha
commit
7ecfbd6913
1 tập tin đã thay đổi với 6 bổ sung0 xóa
  1. 6 0
      docs/_includes/head.html

+ 6 - 0
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);
 		</script>