I have a little function that shows latest activity, it grab timestamp in unix format from the db, and then it echo out with this line:
date(\"G:i:s j M -Y\
something like: $now = time(); $last_midnight = $now - ($now % (24*60*60)); if ($last_access >= $last_midnight) { print "Today"; } elseif ($last_access >= ($last_midnight-(24*60*60)) { Print "Yesterday"; }