Heim  >  Artikel  >  Web-Frontend  >  HTML 头部标记_html/css_WEB-ITnose

HTML 头部标记_html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 11:40:21898Durchsuche

HTML头部标记放在

中,一般包括标题、基底信息、元信息等。

        当前文档的URL全称(基底网址)

    设定基准的文字字体、字号和颜色

        显示在浏览器左上方的标题内容(标签卡上) <p><isindex>    表明该文档是一个可用于检索的网关脚本,由服务器自动建立 </p> <p><meta>    有关文档本身的元信息,如用于查询的关键字、获取该文档的有效期等 </p> <p><style> 设定CSS层叠样式表的内容 </style></p> <p><link>        设定外部文件的链接 </p> <p><script> 设定页面中程序脚本的内容 </script></p> <p>meta元素的属性有两种,name和http-equiv,其中name属性主要用于描述网页,以便于搜索引擎查找和分类 </p> <p><meta name="keyword" content=""> </p> <p><meta name="description" content=""> </p> <p><meta name="generator" content=""> //设置编辑软件的名称 </p> <p><meta name="author" content=""> </p> <p><meta name="robots" content=""> //限制搜索方式 </p> <p>搜索方式:    All(可搜索当前网页及其链接的网页)、Index(表示能搜索当前网页)、Nofollow(表示不能搜索当前网页链接的网页)、Noindex(表示不能搜索当前网页)、None(表示不能搜索当前网页及其链接的网页) </p> <p>设置网页文字和语言的两种方法: </p> <p><meta http-equiv="Content-Type" content="text/html;charset=字符集类型">    <meta http-equiv="Content-Language" content="语言"> </p> <p>在该语法中,http-equiv用于传送HTTP通信协议的标头,两种方式的content不一样,第一种charset=utf,而第二种方式的语言是zh_CN形式。 </p> <p><meta http-equiv="refresh" content="跳转时间;url=链接地址"> //跳转时间的单位是秒 </p> <p><meta http-equiv="expires" content="到期时间"> //到期时间必须是GMT格式的:星期 日 月 年 时 分 秒,而且必须是英文和数字 </p> <p>禁止从缓存中调用(两种方法): </p> <p><meta http-equiv="cache-control" content="no-cache">    <meta http-equiv="pragma" content="no-cache"> </p> <p><meta http-equiv="set-cookie" content="到期时间"> //删除过期cookie 时间格式同样是GMT </p> <p><meta http-equiv="windows-target" content="_top">    //强制打开新窗口</p>
Stellungnahme:
Der Inhalt dieses Artikels wird freiwillig von Internetnutzern beigesteuert und das Urheberrecht liegt beim ursprünglichen Autor. Diese Website übernimmt keine entsprechende rechtliche Verantwortung. Wenn Sie Inhalte finden, bei denen der Verdacht eines Plagiats oder einer Rechtsverletzung besteht, wenden Sie sich bitte an admin@php.cn