why 1 is there on php date function code example
Example 1: php get current year
$currentYear=date("Y");//2019
Example 2: php date
$dateTime = new \DateTime();
/**
* You can get the string by using format
*/
$dateTime->format('Y-m-d H:i:s');
$currentYear=date("Y");//2019
$dateTime = new \DateTime();
/**
* You can get the string by using format
*/
$dateTime->format('Y-m-d H:i:s');