Latest web development tutorials

JavaScript getUTCSeconds () method

Date Object Reference JavaScript Date Object

Examples

According to the return time world Seconds:

var d = new Date();
var n = d.getUTCSeconds();

try it"

Definition and Usage

getUTCSeconds () method returns the time when the world according to the number of seconds (0 to 59).

Coordinated Universal Time (UTC) in seconds when the atomic length based on the time metering system as close as possible in a time when the world.

Tip: When youtune in the world, known as the World unified time, Universal Time, Coordinated Universal Time, abbreviated UTC (Universal Coordinated Time).

Note: UTC time is the GMT (Greenwich Mean) time.


Browser Support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support getUTCSeconds () method


grammar

Date.getUTCSeconds()

return value

类型 描述
Number 返回它的秒字段,该值是一个 0 ~ 59 之间的整数。

technical details

JavaScript version: 1.3


Examples s

More examples

Displays the current UTC time
How getUTCHours (), getUTCMinutes () and getUTCSeconds () to display the current UTC time.


Date Object Reference JavaScript Date Object