I used php strtotime function in my project and it was working fine, but today a user reported an issue, i checked and found strtotime function not giving correct output. My Code is:
echo date('M Y', strtotime('-1 month'));
It is giving output:
Mar 2017 instead of Feb 2017
I checked above code at code online tools and it is giving same output there, So is it php core function issue or i did some mistake? Note: I checked following code online
echo date('Y-m-d', strtotime('-1 month'));
Its output strange me which is
2017-03-02