schema.org/Offer具有类别属性。
项目的类别。较大的符号或斜线可用于非正式地指示类别层次结构。
所以这样的东西会起作用。
<div itemscope itemtype="http://schema.org/Product">
<span itemprop="name">Kenmore White 17" Microwave</span>
<img src="kenmore-microwave-17in.jpg" alt='Kenmore 17" Microwave' />
<div itemprop="aggregateRating"
itemscope itemtype="http://schema.org/AggregateRating">
Rated <span itemprop="ratingValue">3.5</span>/5
based on <span itemprop="reviewCount">11</span> customer reviews
</div>
<div itemprop="offers" itemscope itemtype="http://schema.org/Offer">
<span itemprop="price">$55.00</span>
<link itemprop="availability" href="http://schema.org/InStock" />In stock
<span itemprop="category">LargeCategory > SmallCategory</span>
</div>
</div>
或者
另一种选择是使用 data-vocabulary.org,它的 Product 类中有category属性。谷歌可以,但其他搜索引擎不行。但对于谷歌来说,它会起作用。像这样:
<div itemscope itemtype="http://data-vocabulary.org/Product">
<span itemprop="brand">ACME</span> <span itemprop="name">Executive
Anvil</span>
<img itemprop="image" src="anvil_executive.jpg" />
<span itemprop="description">Sleeker than ACME's Classic Anvil, the
Executive Anvil is perfect for the business traveler
looking for something to drop from a height.
</span>
Category: <span itemprop="category" content="Hardware > Tools > Anvils">Anvils</span>
Product #: <span itemprop="identifier" content="mpn:925872">
925872</span>
<span itemprop="review" itemscope itemtype="http://data-vocabulary.org/Review-aggregate">
<span itemprop="rating">4.4</span> stars, based on <span itemprop="count">89
</span> reviews
</span>
<span itemprop="offerDetails" itemscope itemtype="http://data-vocabulary.org/Offer">
Regular price: $179.99
<meta itemprop="currency" content="USD" />
$<span itemprop="price">119.99</span>
(Sale ends <time itemprop="priceValidUntil" datetime="2020-11-05">
5 November!</time>)
Available from: <span itemprop="seller">Executive Objects</span>
Condition: <span itemprop="condition" content="used">Previously owned,
in excellent condition</span>
<span itemprop="availability" content="in_stock">In stock! Order now!</span>
</span>
</div>
您可以在此处找到有关此词汇的更多信息。