大佬教程收集整理的这篇文章主要介绍了HTML5什么是itemscope属性,它在laymans术语是什么?,大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。
它在HTML5 Microdata API中定义:
@H_301_8@Every HTML element may have an itemscope
attribute specified. The itemscope
attribute is a Boolean attribute.
An element with the itemscope
attribute specified creates a new item,a group of name-value pairs.
换句话说,它是一种将元数据与特定DOM节点相关联的方法。
这由Schema.org API用于关联搜索引擎和社交网络的数据。 Google+ uses schema作为为用户共享的页面提供标题,缩略图和描述的方式。
还应当注意,当为网页提供元数据时,[itemscope]和[itemprop]与Facebook的Open Graph Protocol兼容。可以针对搜索引擎,FACBook和Google在单个< Meta>集合中列出相同的元数据。元素,而不必多次列出相同的信息:
<html itemscope itemtype="http://scheR_891_11845@a.org/WebPage" xmlns:fb="https://www.facebook.com/2008/fbml"> <head> <title>An Example title</title> <Meta content="An Example title" itemprop="name" property="og@R_776_6964@" /> <Meta content="Lorem ipsum dolor sit amet" itemprop="description" name="description" property="og:description" /> <Meta content="http://www.example.com/image.jpg" itemprop="image" property="og:image" /> <Meta content="http://www.example.com/permalink" itemprop="url" property="og:url" /> <link rel="canonical" href="http://www.example.com/permalink" /> </head> <body> ...content... </body> </html>
请注意,在示例中,[itemscope]已添加到< html>元件。这意味着< head>中的任何[itemprop] < body>是WebPage项目的一部分。
以上是大佬教程为你收集整理的HTML5什么是itemscope属性,它在laymans术语是什么?全部内容,希望文章能够帮你解决HTML5什么是itemscope属性,它在laymans术语是什么?所遇到的程序开发问题。
如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。
本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。