psDate() Returns date and time in simple format
Description:
This is just a wrapper for: date("m/d/y") and date("g:i a")
Usage:
$dt = psDate([UNIX_TIME]) $dt = psTime([UNIX_TIME])
Example:
$d = psDate(); // now $t = psTime(); // now print "Date: $d Time: $t";
Code:
function psDate($ts="") { if ($ts == "") { $ts = time(); } return date("m/d/y",$ts); }
function psTime($ts="") { if ($ts == "") { $ts = time(); } return date("g:i a",$ts); }
Changlelog:
02/26/2015 : Added psTime() for simple time
|