So i get a timestamp from my psql database and it is returned like this
2008-08-28 23:12:25.275871
Now i try to truncate it with php like this
Code: Select all
while($row = pg_fetch_array($result)){
$tomorrow = mktime($row['newtime']);
echo $row['newtime'];
echo " - ".date("y/m/d", $tomorrow);it will instead return me this
2008-08-28 23:12:25.275871 - 08/11/19
2008-08-28 20:45:04.281969 - 08/11/19
2008-08-28 18:57:55.362821 - 08/11/19