X
HOME HTML CSS JAVASCRIPT SQL PHP JQUERY ANGULAR XML ASP.NET MORE...
REFERENCES | EXAMPLES | FORUM | ABOUT

HTML DOM Time Object


Time Object

The Time Object is new in HTML5.

The Time object represents an HTML <time> element.

Access a Time Object

You can access a <time> element by using getElementsByTagName():

var x = document.getElementById("myTime"); Try it

Create a Time Object

You can create a <time> element by using the document.createElement() method:

var x = document.createElement("TIME"); Try it

Time Object Properties

Property Description
dateTime Sets or returns the value of the datetime attribute in a <time> element

Standard Properties and Events

The Time object also supports the standard properties and events.


Related Pages

HTML reference: HTML <time> tag



Your suggestion:

Close [X]

Thank You For Helping Us!

Your message has been sent to W3Schools.

Close [X]
Search w3schools.com:

WEB HOSTING

UK Reseller Hosting

WEB BUILDING

Download XML Editor FREE Website BUILDER Free HTML5 Templates FREE Website Templates Free HTML Templates

SHARE THIS PAGE

facebook