Combining seperate Schema.org Organization sections in Microdata

245 views Asked by At

I can't seem to figure out the correct way to combine my logo section, address section and social media into one schema organization section.

The following code is attempting to use the itemref attribute to combine the three separate areas.

<div itemscope itemtype="http://schema.org/Organization" itemref="schemabiz schemabiz2" >
    <a itemprop="url" href="www.address.com">
        <div itemprop=" legalName"><strong>Business Name</strong></div>
    </a>
    <a itemprop="url" href="http://www.website.com">Home</a>
    <img itemprop="logo" src="logo.png" />
</div>

<!-- Some content -->

<div id="schemabiz">
    <div itemprop="address" itemscope itemtype="http://schema.org/PostalAddress">
        <span itemprop="streetAddress">Address</span>
        <span itemprop="addressLocality">City</span>
        <span itemprop="addressRegion">CO</span>
        <span itemprop="postalCode">80525</span>
        <span itemprop="addressCountry">United States</span>
    </div>
</div>

<!-- Some content -->

<div id="schemabiz2" itemscope itemtype="http://schema.org/Organization">
  <a itemprop="sameAs" href="http://www.facebook.com/your-company">FB</a>
  <a itemprop="sameAs" href="http://www.twitter.com/YourCompany">Twitter</a>
</div>
1

There are 1 answers

1
unor On BEST ANSWER

For schemabiz

It works like that.

But you could also omit the outer div and add the id to the PostalAddress item.

So instead of

<div id="schemabiz">
    <div itemprop="address" itemscope itemtype="http://schema.org/PostalAddress">
    </div>
</div>

you could use

<div id="schemabiz" itemprop="address" itemscope itemtype="http://schema.org/PostalAddress">
</div>

For schemabiz2

Don’t use itemscope+itemtype for the referenced element.

So instead of

<div id="schemabiz2" itemscope itemtype="http://schema.org/Organization">
</div>

you should use

<div id="schemabiz2">
</div>