Which function would I use to convert custom formatted dates back to Unix Epoch time?
For example:
("Ymd") -> ("U");
I looked at date("U",strtotime("20140525"));
, but I'm not sure how to fit in the original format Ymd
.
How does that function know that the input format is YYYYMMDD, because it looks like it works.
Thanks
You can use DateTime::createFromFormat():