note 46627 deleted from function.time by sean
| From: | sean@php.net | Date: | Sat, 23 Oct 2004 07:00:08 +0000 |
| Subject: | note 46627 deleted from function.time by sean | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-78985@lists.php.net to get a copy of this message | ||
Note Submitter: jonatan at jpofy dot com
----
I was building a system that needed the current GMT UNIX timestamp, so I made this:
function gmtime($offset=0) {
$time = time() - date("Z") + 3600*($offset+date("I"));
return $time;
}
I thought it strange that this function wasn't already written, but then, it's so simple
that it hardly needs an own function.. I added an an offset variable too since i needed it, and it
wasn't very hard to add it :)