gmdate() is an inbuilt function in PHP and it returns the time in Greenwich Mean Time(GMT). It is used to format a GMT/UTC time.
To display the current date and time
<?php echo gmdate('Y-m-d H:i:s'); //showing current gmt ?>
To display date - World Wide Web Consortium
<?php echo gmdate(DATE_W3C) //showing date - World Wide Web Consortium ?>
To display the date as ISO Format
<?php echo gmdate(DATE_ISO8601); ?>0 0
gmdate function is used to format GMT/UTC date/time.
Version
PHP 4 and above
Syntax
gmdate(format, timestamp)
The return value of this function is a formatted date string and FALSE or E_WARNING on failure.
0 0Please Login to Post the answer