Beispiel #1
0
/**
 * Convert a Unix timestamp to YYYYMMDDHHIISS format, using the internal time zone.
 * If the timestamp is not given, the current time is used.
 * 
 * @param int $timestamp Unix timestamp
 * @return string
 */
function getInternalDateTime($timestamp = null, $format = 'YmdHis')
{
    $timestamp = $timestamp !== null ? $timestamp : time();
    return Rhymix\Framework\DateTime::formatTimestamp($format, $timestamp);
}