When Time Began: The PHP Date Function

PHP has a wonderful function called date(). It simply returns a date, in the format you request, and you can either print it or store it in a variable for later. On its face the date() function is quite simple, but it can be incredibly flexible as well. Let’s take a look at some options.

The formatting of the date output is controlled simply by giving it some letters, like this:

{codecitation}<?php echo date( ‘j F, Y’ ); ?>{/codecitation}



[[ This is a content summary only. Visit http://OSTraining.com for full links, other content, and more! ]]
 •  0 comments  •  flag
Share on Twitter
Published on January 08, 2015 16:45
No comments have been added yet.