Date Handling in PHP

PHP date functions used to display the current date in mm/dd/yyyy, dd/mm/yyyy, and Monday September 1, YYYY are:

07/01/2022

01/07/2022

Friday July 1, 2022

 

PHP date and time functions that display in hh:mm 12 hr clock, hh:mm 24 hr clock, hh:mm:ss 12 hr clock, and hh:mm:ss 24 hr clock are:

10:56

10:56

10:56:20

10:56:20

 

The date 3 days from now is: Monday July 4, 2022

 

The date 7 days from now is: Friday July 8, 2022

 

The date 30 days from now is: Sunday July 31, 2022

 

The date 1 year from now is: Saturday July 1, 2023