使用JSON-LD获取组织详细信息以及网页内容

时间:2018-01-26 09:27:35

标签: schema.org json-ld

我正在为一家物流公司开发一个网站。我想要包含JSON-LD,但不仅包括组织详细信息,还包括网页中的内容,但不知道如何执行此操作。

<script type="application/ld+json">
{
    "@context": "http://schema.org/",
    "@type": "Organization",
    "url": "url",
    "description": "description",
    "address": {
         "@type": "PostalAddress",
         "addressCountry": "country",
         "addressLocality": "state",
         "addressRegion": "state",
         "postalCode": "zip code",
         "streetAddress": "address"
    },
    "sameAs": [
        "https://www.facebook.com/xyz/",
        "https://plus.google.com/u/0/000000000",
        "https://twitter.com/xyz"
        ],
    "aggregateRating": {
        "@type": "AggregateRating",
        "ratingValue": "4.9",
        "ratingCount": "5"
        },
     "email": "email",
     "logo": {
         "@type": "ImageObject",
         "url": "link",
         "width": "386",
         "height": "60"
         },
     "founder": {
         "@type": "Person",
         "name": "xyz"
     },
     "foundingDate": "2013",
     "name": "abc",
     "telephone": "999999999"
     }
</script>
<script type = "application/ld+json"> {
      "@context": "http://schema.org",
      "@type": "WebSite",
      "url": "https://www.example.com/",
      "potentialAction": {
         "@type": "SearchAction",
         "target": "https://query.example.com/search?q={search_term_string}",
         "query-input": "required name=search_term_string"
      }
   } </script>

我应该如何为不同的图像编写JSON-LD,比如我的网页中是否有多个图像,那么如何使用组织细节以及所有图像构建JSON-LD?

<video loop="" muted="" preload="metadata" poster="poster.jpg" class="responsive-video" autoplay="autoplay">
      <source src="ABC.mp4" type="video/mp4">
      <source src="ABC.webm" type="video/webm">
      <img src="./img/ABC.jpg"  />//FALL BACK IMAGE
</video>
<picture>
      <img src="./img/c.png" alt="" class="responsive-img" />
</picture>
<picture>
      <img src="./img/abc.png" alt="" class="responsive-img" />
</picture>
<picture>
      <img src="./img/d.png" alt="" class="responsive-img" />
</picture>

如何链接图像和组织的JSON-LD?

1 个答案:

答案 0 :(得分:0)

如果Organization

,则只能提供Organization的图片
  • 该组织的徽标(logo)或
  • 组织的图像,或代表组织的图像(ìmage)。

如果图像是页面内容的一部分,并且页面由组织发布,则将图像添加到Organization项目是没有意义的。相反,将图像添加到他们所属的项目中(例如,Article以防它是文章),然后提供Article作为const arrayItems = [<div key=“0” onClick={this.bindClick}>A</div>]; 的{​​{3}}。< / p>