Załóżmy, że mam tę prostą stronę HTML o facecie znalezienie pracy:Jak powiązać elementy w schema.org?
<!DOCTYPE HTML>
<html>
<head>
<meta charset="utf-8">
<title>New Job for John Doe</title>
</head>
<body>
<h1>New Job for John Doe</h1>
<p>This week John Doe accepted an offer to become a Software Engineer at MITRE. John graduated from MIT in 2005 with a BS in Computer Science. He previously worked at a small company near Boston. Blah, blah, blah.</p>
<p>The MITRE Corporation is a not-for-profit organization chartered to work in the public interest. The MITRE Corporation has two principal locations: Bedford, Massachusetts, and McLean, Virginia. Blah, blah, blah.</p>
</body>
</html>
Jeśli dodać dane semantyczne używając słownictwa schema.org, może to wyglądać tak:
<!DOCTYPE HTML>
<html>
<head>
<meta charset="utf-8">
<title>New Job for John Doe</title>
</head>
<body>
<h1>New Job for John Doe</h1>
<p itemscope itemtype="http://schema.org/Person">This week John Doe accepted an offer to become a <span itemprop="jobTitle">Software Engineer</span> at <span itemprop="worksFor">MITRE</span>. John graduated from <span itemprop="alumniOf">MIT</span> in 2005 with a BS in Computer Science. He previously worked at a small company near Boston. Blah, blah, blah.</p>
<p itemscope itemtype="http://schema.org/Corporation">The MITRE Corporation is a not-for-profit organization chartered to work in the public interest. The MITRE Corporation has two principal locations: <span itemprop="location">Bedford, Massachusetts</span>, and <span itemprop="location">McLean, Virginia</span>. Blah, blah, blah.</p>
</body>
</html>
Pierwszy akapit dotyczy oczywiście osoby, John Doe, a drugi akapit dotyczy firmy, The MITER Corporation. Ale "MITER" w pierwszym akapicie jest taki sam jak "Korporacja MITER" w drugim. W jaki sposób jawnie deklaruję, że są one takie same za pomocą schema.org?
Próbowałem tego, [nie wyglądało na to, że wpłynęło to faktycznie na model danych] (http://goo.gl/agxIv). – robertc
itemref służy tylko do wskazania dodatkowych właściwości dla paska przedmiotów. W takim przypadku tag ten musiałby być również typem korporacyjnym. a tag z id = "The MitreCorporation" nie może być itemcope. –