2

当我使用 Google 结构化数据测试工具测试此页面时,我收到以下消息:

hproduct
availability:   in_stock
brand-name: GREEN HILL
category:   Bokserskie
description:    Bardzo trwałe rękawice bokserskie GREEN HILL TIGER (10 OZ) Producent rękawic: Green Hill - Dostawca profesjonalnego sprzętu na szereg międzynarodowych imprez bokserskich (np. Olimpiada-...
fn: Rękawice bokserskie GREEN HILL - TIGER 10 oz. Czerwone
photo:  http://www.boxinghome.pl/environment/cache/images/300_200_productGfx_a52dca0949dd886f787e4e34d683741a.jpg
price:  189
currency:   PLN
Błąd: In order to generate a preview with rich snippets, either price or review or availability needs to be present.

我不知道我错过了什么。你能帮助我吗?

4

1 回答 1

2

您必须指定报价详细信息 itemscope 并将价格和可用性嵌套在其中。

<span itemprop="offerDetails" itemscope itemtype="http://data-vocabulary.org/Offer">
INSERT PRICE, AVAILIBILITY and REVIEW metadata HERE
</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>

来自 Google 的关于微数据语法的示例

关于丰富网页摘要的网站管理员 stackexchange 问题

于 2014-06-29T07:33:34.413 回答