3v4l.org

run code in 300+ PHP versions simultaneously
<?php // Prints the day, date, month, year, time, AM or PM echo date("D, j F Y h:i:s") . "<br>"; // Print the array from getdate() print_r(getdate()); echo "<br><br>"; // Return date/time info of a timestamp; then format the output $mydate=getdate(date("U")); echo "$mydate[weekday], $mydate[month] $mydate[mday], $mydate[year]";

preferences:
37.57 ms | 402 KiB | 5 Q