摘要: 1 function dateToTimestamp(date) { 2 //方法一 3 var newDate = new Date(); 4 newDate.setFullYear(date.substring(0,4)); 5 newDate.setMonth(date.substring(5,7)-1); 6 console.log('3--' + date.substring(8,10)); 7 newDate.setDate(date.substring(8,10)); ... 阅读全文
posted @ 2014-03-13 14:30 幻星宇 阅读(1575) 评论(0) 推荐(0) 编辑
摘要: 当程序没有问题,而php显示的日期和js显示的日期不一致,相差一天的时候或者其它,一定要看看php.ini中时区的配置是否合理。 阅读全文
posted @ 2014-03-13 14:27 幻星宇 阅读(275) 评论(0) 推荐(0) 编辑