Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
247 views
in Technique[技术] by (71.8m points)

html - How to use Microdata throughout a LocalBusiness website

I am getting involved into Microdata and rich snippets for leading better search results. I am kind of confused about where to set the itemscope for a LocalBusiness and if it is good or bad to have it repeated through out the whole website over and over.

For example on the header that repeats all over the site, page after page, I have the business name, telephone, address, logo, description, etc. Is it good to repeat the same itemscope over and over on each page, or it should be only added to one page, for instance only on the index or only on the contact page?

Simplified version (no address, etc.):

<section itemscope itemtype="http://schema.org/LocalBusiness">
     <div id="logo">
       <div class="wrapper">
        <img itemprop="logo" src="images/logo.png" alt="My Company Logo" title="My Company" />
        <h1 itemprop="name">My Cmpany</h1>
       </div>
    </div>
    <div id="tel1"> 
        <a href="tel:+5160000001" itemprop="telephone">5160000001</a>
    </div>
     <div id="tel2">
        <a itemprop="telephone" href="tel:+5160000000">5160000000</a>
    </div>
</section>

Another question is, if I have a page with a list of partners and their contact information, is it ok to repeat several itemscope attributes and itemtype="LocalBusiness" for each business or this might mislead Google about the original LocalBusiness of the site?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

You should add the Microdata on every page … because of reasons.

If you have a page where your business data is duplicated (e.g., a contact page where the business contact information is in the site header and in the page body), you should only markup one of these instances. Otherwise you’d create two LocalBusiness entities for the same entity.

If you have a page where your and partner business data is contained, you should mark up each business separately. So each business entity is represented by an own LocalBusiness entity.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...