本文介绍了你可以在页面上有多个itemprop = description吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我似乎无法在任何地方找到答案。



我有 itemscope itemtype =http:// data -vocabulary.org/Review在身体标记上。



现在,网页上的内容分布在多个div上, 。如果我要包装所有内容,那么其他内容实际上会在主体之前出现,所以我需要能够将 itemprop =description放在多个div上。



它似乎在google snippets工具中显示为OK,但我想知道它是否正常或者它是否只考虑了1? p>

解决方案

好的,您正在为同一项目添加几个描述。从Microdata的角度来看,这很好。



只有微数据(参见示例),而不同属性相互无序。

这是否应该意味着所有这些描述应该合并到一个描述(您的用例)中,或者如果这些是替代描述(例如,可以提供多种语言的描述) )。

但消费者(如谷歌)如何解释这一点,取决于他们;它可能是未知的/无证的;它可能每天都在改变。关于这个的讨论可能是关于SO的话题。它可能更适合。


I can't seem to find the answer for this anywhere.

I've got itemscope itemtype="http://data-vocabulary.org/Review" on the body tag.

Now the content on the page is spread across multiple divs with images and such between. If I were to wrap it all, then other content would actually come first before the main body, so I need to be able to put the itemprop="description" on multiple divs.

It seems to show up OK in the google snippets tool but I want to know if it would be fine or whether it'd only take 1 into account?

解决方案

Well, you are adding several descriptions for the same item. That’s fine from the Microdata perspective.

Microdata only defines that an item’s properties with the same name are ordered (see the examples), while different properties are "unordered with respect to each other".

Microdata does not define if this should mean that all these descriptions should be consolidated into one description (your use case), or if these are alternative descriptions (for example one could offer descriptions in several languages).

But how consumers (like Google) interpret this, that is up to them; it might be unknown/undocumented; it might change daily. Discussion about this is probably off-topic on SO; it might better fit on Webmasters SE.

这篇关于你可以在页面上有多个itemprop = description吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-07 02:33