2017-01-24 33 views
1

我使用基於巴西的畫廊的itemscopes,但他們也有其他地方的其他兩個展覽位置,所有這些都顯示在頁腳中。多項目鏡頭位置方案

我可以在頁面上使用多個位置方案嗎?如果是這樣,我將如何做到這一點?如果我只是重複以下內容,還是應該將第一個屬於組織並將其他兩個分割爲Places,那麼這很好嗎?

<p itemscope itemtype="http://schema.org/Place"> 
    <span itemprop="name" style="display:none;">Gallery</span> 
    <span itemprop="address" itemscope itemtype="http://schema.org/PostalAddress"> 
    <span itemprop="streetAddress">{!! $street !!}</span><br> 
    <span itemprop="addressLocality">{!! $town !!}</span><br> 
    <span itemprop="postalCode">{!! $postal !!}</span> 
    <span itemprop="addressRegion">{!! \App\Info::val('adresscountry') !!}</span><br> 
    <span itemprop="telephone">{!! $phone !!}</span><br><br> 
    <span>{!! $openinghours !!}</span><br><br> 
    <span itemprop="email">[email protected]</span><br><br> 
    </span> 
</p> 

這是一個組織擁有三個舉辦展覽的地方。如果每個地方都會出現在搜索引擎上,那麼不需要特別的展覽。

回答

1

請注意,以下內容不一定會在搜索引擎中產生豐富的結果。對於Google搜索,似乎他們不會爲地點提供豐富的結果(即使他們願意,也可能需要爲每個地點設置專門的頁面)。但是,他們有一個rich result for events

你可以提供一個Organization項目有三個location值:

<div itemscope itemtype="http://schema.org/Organization"> 
    <div itemprop="location" itemscope itemtype="http://schema.org/Place" id="loc-1"><!-- location 1 --></div> 
    <div itemprop="location" itemscope itemtype="http://schema.org/Place" id="loc-2"><!-- location 2 --></div> 
    <div itemprop="location" itemscope itemtype="http://schema.org/Place" id="loc-3"><!-- location 3 --></div> 
</div> 

對於每個ExhibitionEvent,你可以通過引用它的位置(假設地方都在活動頁面的頁腳的一部分,太) itemref屬性:

<div itemscope itemtype="http://schema.org/ExhibitionEvent" itemref="loc-2"> 
</div> 
+0

完美,我會試試這個,謝謝先生! – HSRF