如何创建标记以嵌入评论者的职业、公司和位置?

How to create a markup to embed reviewer's occupation, company and location?

<div itemprop="review" itemscope itemtype="http://schema.org/Review">
  <p itemprop="reviewBody">
    Lorem ipsum dolor sit a met
  </p>
  <p itemprop="author">Dr. Exaggerate</p>
  <small>CEO, Organisation, Country</small>
</div>

如何为评论者的职业、公司和位置(特别是国家/地区)添加正确的项目属性?

首先,按照这里的例子(有用): https://schema.org/Person

author 值应为以下类型之一:

  • 组织

我们使用 Person 属性来提供有关作者的更多语义数据。

职位

https://schema.org/jobTitle

<span itemprop="jobTitle">CEO</span>

适用于

https://schema.org/worksFor (expected Organization type)

<span itemprop="worksFor">Nike</span>

工作地点

https://schema.org/workLocation (或使用 address 属性 - 与您的数据相关)。

<div itemprop="workLocation" itemscope itemtype="http://schema.org/PostalAddress">
    <span itemprop="addressLocality">Paris, France</span>,
</div>

完整示例

<div itemprop="review" itemscope itemtype="http://schema.org/Review">
  <p itemprop="reviewBody">
    Lorem ipsum dolor sit a met
  </p>
  <div itemprop="author" itemscope itemtype="http://schema.org/Person">
   <p itemprop="name">Dr. Chapaklal</p>
   <span itemprop="jobTitle">CEO</span>
   <span itemprop="worksFor">Nike</span>
   <div itemprop="address" itemscope itemtype="http://schema.org/PostalAddress">
    <span itemprop="streetAddress">
      20341 Whitworth Institute
      405 N. Whitworth
    </span>
    <span itemprop="addressLocality">Paris, France</span>,
  </div>
  </div>
</div>