【发布时间】:2018-05-26 03:07:05
【问题描述】:
我正在尝试为公司/子公司及其网站完成机器可理解的关系描述。假设有一家母公司和两家子公司,它们都有自己的网站。我为每个主页部署一个Organization 脚本和一个WebSite 脚本。
父组织的 JSON-LD 读取:
<script type="application/ld+json">
{
"@context": "http://www.schema.org",
"@type": "Organization",
"@id": "https://www.parentorg.com/#organization",
"name": "Parent Org",
"legalName": "Parent Org Inc.",
"description": "Description of company",
"foundingDate": "1978",
"logo": "https://www.parentorg.com/images/logo.png",
"image": "https://www.parentorg.com/de/images/outside.jpg",
"url": "https://www.parentorg.com/",
"address": {
"@type": "PostalAddress",
"streetAddress": "Street 110",
"addressLocality": "City",
"postalCode": "XX XXX",
"addressCountry": "XX"
},
"contactPoint": {
"@type": "ContactPoint",
"contactType": "customer support",
"telephone": "+12-345-678-91011",
"email": "contact@parentorg.com"
},
"sameAs": [
"https://twitter.com/parentorg/",
"https://www.instagram.com/parentorg/",
"https://www.youtube.com/user/parentorg/",
"https://plus.google.com/parentorg"
],
"subOrganization": [
{
"@type": "Organization",
"@id": "https://www.subsidiary-one.de/#organization",
"name": "Subsidiary One"
},
{
"@type": "Organization",
"@id": "https://www.subsidiary-two.de/#organization",
"name": "Subsidiary Two"
}
]
}
</script>
父网站的 JSON-LD 是:
<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "WebSite",
"@id": "https://www.parentorg.com/#website",
"url": "https://www.parentorg.com/",
"author": {
"@type": "Organization",
"@id": "https://www.parentorg.com/#organization",
"name": "Parent Org"
}
}
</script>
现在子公司的组织 JSON-LD 包含 parentOrganization 属性:
"parentOrganization": {
"@type": "Organization",
"@id": "https://www.parentorg.com/#organization",
"name": "Parent Org"
}
这是交叉引用这些实体的好方法吗?当引用了 URI 时,我是否还需要在 subOrganization、parentOrganization 和 author 中写出 name 属性?
【问题讨论】:
标签: schema.org json-ld structured-data