Using Various Formatting Strings With Date().

 
<?php $time = time();
$formats = array('U','r','c','l, F jS, Y, g:i A','H:i:s D d M y','m/j/y g:i:s O (T)' ); foreach($formats as $format)
    echo "<p><b>$format</b>: " . date($format, $time) . "</p>\n";
?>

Enjoyed this post? Share it!

 

Leave a comment

Your email address will not be published.