iphone web 时间 问题
2021-01-08 21:30
标签:join alert push split style 问题 length class rgb iphone web 时间 问题 标签:join alert push split style 问题 length class rgb 原文地址:https://www.cnblogs.com/enych/p/14244606.html alert(CheckObjTime2(‘2021-1‘))
alert(CheckObjTime2(‘2021-1-1‘))
alert(‘好了‘)
var time_obj = ‘2021-1‘;
//格式化为三位
var d_001 = time_obj.split(‘-‘);
if (d_001.length == 2) {
d_001.push(‘01‘);
}
time_obj = d_001.join(‘-‘);
alert(CheckObjTime2(time_obj))
上一篇:HTML5基础