当前位置:网站首页>js获取浏览器系统语言
js获取浏览器系统语言
2022-07-06 12:08:00 【搬砖的前端】
js获取浏览器系统语言
var lan = navigator.language;
中文:‘zh-CN’
如果获取语言数组则使用:
navigator.languages
根据系统语言默认项目语言类型,现实场景使用不多,国际化项目需要处理。
实际项目开发使用,亲测靠谱能用
边栏推荐
- Learning and Exploration - Seamless rotation map
- 腾讯字节阿里小米京东大厂Offer拿到手软,老师讲的真棒
- [translation] linkerd's adoption rate in Europe and North America exceeded istio, with an increase of 118% in 2021.
- Wonderful coding [hexadecimal conversion]
- AsyncHandler
- 理解 YOLOV1 第二篇 预测阶段 非极大值抑制(NMS)
- 系统性详解Redis操作Hash类型数据(带源码分析及测试结果)
- Zero foundation entry polardb-x: build a highly available system and link the big data screen
- 腾讯T3大牛手把手教你,大厂内部资料
- 转让malloc()该功能后,发生了什么事内核?附malloc()和free()实现源
猜你喜欢

(3) Web security | penetration testing | basic knowledge of network security construction, IIS website construction, EXE backdoor generation tool quasar, basic use of

Understand yolov1 Part II non maximum suppression (NMS) in prediction stage

社招面试心得,2022最新Android高频精选面试题分享
Classic 100 questions of algorithm interview, the latest career planning of Android programmers

系统性详解Redis操作Hash类型数据(带源码分析及测试结果)

Cesium 点击绘制圆形(动态绘制圆形)

Configuration and simple usage of the EXE backdoor generation tool quasar

利用 clip-path 绘制不规则的图形
In depth analysis, Android interview real problem analysis is popular all over the network

How to customize animation avatars? These six free online cartoon avatar generators are exciting at a glance!
随机推荐
redisson bug分析
Spark foundation -scala
信息系统项目管理师---第八章 项目质量管理
POJ 3207 Ikki's Story IV – Panda's Trick (2-SAT)
Understand yolov1 Part II non maximum suppression (NMS) in prediction stage
Learning and Exploration - Seamless rotation map
新一代垃圾回收器—ZGC
From spark csc. csr_ Matrix generate adjacency matrix
RT-Thread 组件 FinSH 使用时遇到的问题
爬虫(14) - Scrapy-Redis分布式爬虫(1) | 详解
Appx代码签名指南
PowerPivot——DAX(初识)
Web开发小妙招:巧用ThreadLocal规避层层传值
MySQL information schema learning (I) -- general table
Mysql Information Schema 学习(一)--通用表
Cf960g - bandit Blues (type I Stirling number +ogf)
系统性详解Redis操作Hash类型数据(带源码分析及测试结果)
腾讯架构师首发,2022Android面试笔试总结
AsyncHandler
腾讯安卓开发面试,android开发的基础知识