PHP - function to get UTC timestamp of current date time

By [)ia6l0 iii

Helper function to get UTC timestamp of current date time

var $ct_time ;

function GetUTCTimestamp()
{
$ct_time = mktime();
     return gmdate('Y-m-d\TH:i:s',$ct_time)."Z";
}

Related FAQs

Use the file_get_contents method to read the file contents.
Use the $_GET function to read querystring values. For e.g. the following line reads a querystring key - qs
PHP - function to get UTC timestamp of current date time  (1293 Views)