summaryrefslogtreecommitdiff
path: root/ext/date/tests/date_timestamp_set.phpt
blob: d17ffcd9858dfda9a7f36e04e4e8ac30f6017618 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
--TEST--
Test the basics to function date_timestamp_set().
--CREDITS--
Rodrigo Prado de Jesus <royopa [at] gmail [dot] com>
--INI--
date.timezone = UTC;
date_default_timezone_set("America/Sao_Paulo");
--FILE--
<?php
$dftz021 = date_default_timezone_get(); //UTC

$dtms021 = date_create();

date_timestamp_set($dtms021, 1234567890);

var_dump(date_format($dtms021, 'B => (U) => T Y-M-d H:i:s'));
?>
--EXPECT--
string(47) "021 => (1234567890) => UTC 2009-Feb-13 23:31:30"