kiran
answered Aug 19 '21 00:00
to get current date and time can be got by date() function in php
date() function need format to display date and time
date() function return server date and time.
<?php
echo date('d-m-Y H:i:s'); // 19-08-2021 16:23:58
?>
above code will print date in day-month-Year Hour:Minute:Second format