$month = I('month');
if(empty($month)){//没有设置月份,取当月数据
$month = date('Y-m');
}
$year = gmdate("Y", strtotime($month));
$month_start = strtotime($month);//指定月份月初时间戳
$month_end = mktime(23, 59, 59, date('m', strtotime($month))+1, 0,$year);//指定月份月末时间戳

posted on 2018-06-29 17:12  躺枪  阅读(183)  评论(0编辑  收藏  举报