花费 6 ms
php strtotime 获取上一个月或下一个月的坑

在平时的业务逻辑中经常会遇到用strtotime('last month')或strtotime('-1 month') 获取上一个月, strtotime('next month')或strtotime('+1 month') 获取下一个月 但是在月末,如果前后两个月的天数不一样 ...

Fri Nov 01 03:40:00 CST 2019 0 891

 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM