MySQL 日期时间函数常用总结
获得当前日期+时间(date + time)1.1函数:now() 相关函数:current_timestamp(),localtime(),localtimestamp() 举例说明:2. 获得当前日期(date) 函数:curdate() 相关函数:current_date(),current_
获得当前日期+时间(date + time)1.1函数:now() 相关函数:current_timestamp(),localtime(),localtimestamp() 举例说明:2. 获得当前日期(date) 函数:curdate() 相关函数:current_date(),current_
实现代码如下:function getLocalTime(nS) {return new Date(parseInt(nS) * 1000).toLocaleString().replace(/:\d{1,2}$/,' ');}alert(getLocalTime(1293072805));结果是2