When I pass ‘7.12.60’ to strtotime, it returns timestamp of today! I know strtotime guesses the format of the given string but here the value is not correct at all! it just returns today’s timestamp:
echo date( 'Y-m-d', strtotime('7.12.60') ); // outputs 2022-01-05!
What i expect is to receive a false or a correct value and not a made up one
Advertisement
Answer
As mentioned in comments of @aynber and others. It was considering it as a time and not a date, I added a time (00:00:00) to the end of the string and now it is returning false.
Thank you very much for your help