主要用strtotime()这个函数
php 获得前一个月的月份
date("Y-m-d",strtotime("last month"));
php获得给定时间的前一个月时间
$record="20101001";
date("Ymd",strtotime("last month",strtotime($record)));
php获得(给定时间的)前一个月时间
最新推荐文章于 2024-03-07 15:51:01 发布
主要用strtotime()这个函数
php 获得前一个月的月份
date("Y-m-d",strtotime("last month"));
php获得给定时间的前一个月时间
$record="20101001";
date("Ymd",strtotime("last month",strtotime($record)));