我是Google丰富网页摘要的新手,我对Google丰富网页摘要进行了一些基础研究,并将以下代码添加到我的网站:
<div class='reiew-rating'>
<div itemscope itemtype="http://schema.org/Review">
<div itemprop="itemReviewed" itemscope itemtype="http://schema.org/Thing">
<meta itemprop="name" content=" Interview questions" />
<meta itemprop="description" content=" for entry level/juniors/freshers & experienced/seniors" /><meta itemprop="url" content="" />
<span itemprop="author" itemscope itemtype="http://schema.org/Person">
<meta itemprop="name" Content="Suresh babu mamidala">
</span>
<img id="6_1" src="http://callinterview.com/images/rating_full.png" alt="rating_1" data-rat="1" >
<img id="6_2" src="http://callinterview.com/images/rating_full.png" alt="rating_2" data-rat="2" >
<img id="6_3" src="http://callinterview.com/images/rating_full.png" alt="rating_3" data-rat="3" >
<img id="6_4" src="http://callinterview.com/images/rating_full.png" alt="rating_4" data-rat="4" >
<img id="6_5" src="http://callinterview.com/images/rating_avg.png" alt="rating_5" data-rat="5" >
</div>
<div property="aggregateRating" typeof="AggregateRating">
<span property="ratingValue">4.5</span>
<meta property="bestRating" content="5"/>
<meta property="worstRating" content="1"/>
based on <span property="ratingCount">7869</span> ratings
</div>
<span itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
<meta itemprop="name" content="Callinterview.com">
</div>
</div>
当我在Google structured data testing tool中测试时,我面临以下错误/ s:
Google不会识别属性作者Thing类型的对象。
需要作者字段的值。
如何解决这个问题?
答案 0 :(得分:0)
您将author
属性添加到Thing
:
<div itemprop="itemReviewed" itemscope itemtype="http://schema.org/Thing">
<!-- … -->
<span itemprop="author" itemscope itemtype="http://schema.org/Person">
<!-- … -->
</span>
</div>
但author
property未定义Thing
type。
如果它是author
的{{1}},则必须确保不要将其嵌套在不同的Review
下,例如:
itemscope