我认为标记这个特定场景的正确方法是在单个Product中嵌套多个Offer。要为每个优惠添加附加信息,请使用IndividualProduct。我不是 100% 确定,但这似乎在 Google 结构化数据测试工具中运行良好。
看起来 schema.org 仍在更新以标记产品的新方法。schema.org 项目从Good Relations电子商务产品词汇表中提取了大量结构。有关新词汇项目的更多信息,请参阅使用 Schema.org 的电子商务 SEO 获得了更多粒度。
假设我们想在网站上列出有关待售的苏门答腊咖啡豆的信息。我们想出售两种不同尺寸(12 盎司和 16 盎司),每种尺寸不同的价格。但是,两种产品尺寸应具有相同的图像(只是咖啡豆)和名称。该结构将类似于:
Product (name, description, and image)
aggregateRating
Offer (price and priceCurrency)
IndividualProduct (sku and weight)
Offer (price and priceCurrency)
IndividualProduct (sku and weight)
将以下内容复制并粘贴到 Google 的结构化数据测试工具中,以查看 Google 将如何解释 HTML。
jsFiddle display
<article class="product" itemscope itemtype="http://schema.org/Product">
<div class="images">
<a href="images/product.jpg">
<img alt="Sumatra Coffee Beans" itemprop="image" src="images/product.jpg">
</a>
</div>
<div class="content">
<header>
<h1 itemprop="name">Sumatra Coffee Beans</h1>
</header>
<div class="code">
<span class="label">Item Number:</span>
<span itemprop="productID">sumatra-coffee</span>
</div>
<div itemprop="description">
<p>Error 418</p>
</div>
<div class="reviews" itemprop="aggregateRating" itemscope itemtype="http://schema.org/AggregateRating">
<div class="details">
Rated <span itemprop="ratingValue">4.5</span>/5
</div>
<div class="count">
(<span itemprop="reviewCount">9</span> reviews)
</div>
</div>
<div class="offer" itemprop="offers" itemscope itemtype="http://schema.org/Offer">
<div itemprop="itemOffered" itemscope itemtype="http://schema.org/IndividualProduct">
<span class="sku" itemprop="sku">scb-ov1</span>
– (<span itemprop="weight">12 oz.</span>)
</div>
<div class="price">$<span itemprop="price">14.99<span></div>
<meta content="USD" itemprop="priceCurrency">
</div>
<div class="offer" itemprop="offers" itemscope itemtype="http://schema.org/Offer">
<div itemprop="itemOffered" itemscope itemtype="http://schema.org/IndividualProduct">
<span class="sku" itemprop="sku">scb-ov2</span>
– (<span itemprop="weight">16 oz.</span>)
</div>
<div class="price">$<span itemprop="price">20.99</span></div>
<meta content="USD" itemprop="priceCurrency">
</div>
</div>
</article>