PHP snippets dates PHP DateTime
Working with dates in yyyy-mm-dd format in PHP with the DateTime class. How to evaluate if an input is a valid date in yyyy-mm-dd input and formatting the DateTime object as a string.