在HTML文档中包含元数据

PHPz
PHPz 转载
2023-08-19 15:57:13 324浏览

在HTML文档中包含元数据

属性

描述

Name

author

description

keywords

generator

revised

others

属性的名称。

content

文本

定义与http-equiv或name关联的元信息。

http-equiv

content-type

expires

refresh

set-cookie

将content属性连接到HTTP头。

scheme

文本

定义用于解释content属性值的格式。

示例

您可以尝试运行以下代码来包含元数据:

<html>
   <head>
      <title>HTML meta tag</title>
      <meta name = "keywords" content = "HTML, meta tag, metadata" />
      <meta name = "description" content = "Description of the document" />
      <meta http-equiv = "refresh" content = "10" />
   </head>
   <body style = "background-color:gray">
      Document content goes here
   </body>
</html>

以上就是在HTML文档中包含元数据的详细内容,更多请关注php中文网其它相关文章!

声明:本文转载于:tutorialspoint,如有侵犯,请联系admin@php.cn删除