PHP function microtime()

Availability in PHP 4.0

Return current Unix timestamp with microseconds

Parameters

Parameter Data type Default value Note
$get_as_float bool null When called without the optional argument, this function returns the string "msec sec" where sec is the current time measured in the number of seconds since the Unix Epoch (0:00:00 January 1, 1970 GMT), and msec is the microseconds part. Both portions of the string are returned in units of seconds.

Return values

mixed

Other resources

Official microtime documentation

Newsletter

Nejlepsi tipy a triky o PHP do Vaseho e-mailu. Clanky a novinky nejen ze sveta PHP a programovani.