strtotime of BUG

strtotime ( '+ 1 month'), strtotime ( '- 1 month') will have encountered a problem in month 28, 31 days, such as strtotime ( '+ 1 month', strtotime ( '2019-10-31 ')) will jump to December rather than November;

So the general use 

strtotime('last day of +1month')

 

or

strtotime('first day of +1 month')

 

Guess you like

Origin www.cnblogs.com/pyspang/p/11871012.html