php xurrent unix timestamp code example
Example 1: php datetime object get unix timestamp
$date = new DateTime();
echo $date->getTimestamp();
Example 2: php time
<?php
$t=time();
echo($t . "<br>");
echo(date("Y-m-d",$t));
?>
$date = new DateTime();
echo $date->getTimestamp();
<?php
$t=time();
echo($t . "<br>");
echo(date("Y-m-d",$t));
?>