problem
bootstrap3 used bootstrap-datetimepicker trouble setting Chinese language problem
Solution
bootstrap-datetimepicker use when first introduced momentjs moment.js default display in English.
want to show the Chinese by the momentjs download references moment-with-locales.min.js to set the language.
Since the moment-with-locales. min.js file is too large, all options to introduce Chinese language pack github address
Found in the locale zh-cn.js
<!--bootstrap 时间控件 -->
<link rel="stylesheet" href="bootstrap-timepicker.min.css"/>
<script src="moment.min.js"></script>
<script src="bootstrap-datetimepicker.min.js"></script>
<script src="zh-cn.js"></script>
<script>
$('#date-timepicker').datetimepicker({
locale: moment.locale('zh-cn') //引入中文语言
...
})
</script>
to sum up
Omitted some key stakeholders bootstrap css, js files, simply record learning problems, please correct me if problems