I have the array of dates in Y-m-d H:i:s
format like:
array(5) {
[0]=> string(19) "2012-06-11 08:30:49"
[1]=> string(19) "2012-06-07 08:03:54"
[2]=> string(19) "2012-05-26 23:04:04"
[3]=> string(19) "2012-05-27 08:30:00"
[4]=> string(19) "2012-06-08 08:30:55"
}
I would like to know the most recent date.
In other words, today is June 13th 2012, which datetime is closest to today's date?
From my sample array, I am expecting 2012-06-11 08:30:49
.
How can I do that?