Home > Web Front-end > HTML Tutorial > What is the use of time tag?

What is the use of time tag?

云罗郡主
Release: 2019-02-21 15:10:58
Original
5068 people have browsed it

What is the use of time tag?

The time tag defines a Gregorian time (24-hour clock) or date. The time and time zone offset are optional. This element is capable of encoding the date and time in a machine-readable way, such that , for example, user agents can add birthday reminders or scheduled events to the user's calendar, and search engines can generate smarter search results.

html time tag Syntax

Function: Define the Gregorian calendar time (24-hour clock) or date, time and time zone offset are optional.

Description: This element can encode the date and time in a machine-readable way so that, for example, user agents can add birthday reminders or scheduled events to the user's calendar, and search engines can Ability to generate smarter search results.

Note: The

html time tag example

<!DOCTYPE HTML>
<html>
<body>
<p>
我们在每天早上 <time>9:00</time> 开始营业。
</p>
<p>
我在 <time datetime="2010-02-14">情人节</time> 有个约会。
</p>
</body>
</html>
Copy after login


The above is the detailed content of What is the use of time tag?. For more information, please follow other related articles on the PHP Chinese website!

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template