js时间字符串转时间戳 mysql 2021-07-25 2,158 阅读1分钟 var str='2020-10-20 12:00:00' new Date(str.replace(/-/g,'/')).getTime() //当前时间戳 new Date().getTime()