Posted By

jknight42 on 01/29/12


php month time day year date

Versions (?)

PHP display date: year, month, day, time, etc.

 / Published in: PHP


Just a few quick functions to display the date in PHP.

  1. <?php echo date("l"); ?> // Day of the week, ie: Monday
  2. <?php echo date("Y"); ?> // Year, ie: 2012
  3. <?php echo date("F j, Y, g:i a"); ?> // Date and time, ie: March 10, 2001, 5:16 pm

Report this snippet  

You need to login to post a comment.