在搜索引擎優化條件...schema.org SiteNavigationElement的正確用法是什麼?
是最好把計劃放在包含所有鏈接的父級?
<nav itemscope="itemscope" itemtype="http://www.schema.org/SiteNavigationElement">
<a href="#">Link 1</a>
<a href="#">Link 2</a>
<a href="#">Link 3</a>
</nav>
......還是應該將每個鏈接視爲自己的元素?
<nav>
<span itemscope="itemscope" itemtype="http://www.schema.org/SiteNavigationElement">
<a itemprop="url" href="#">
<span itemprop="name">Link 1</span>
</a>
</span>
<span itemscope="itemscope" itemtype="http://www.schema.org/SiteNavigationElement">
<a itemprop="url" href="#">
<span itemprop="name">Link 2</span>
</a>
</span>
<span itemscope="itemscope" itemtype="http://www.schema.org/SiteNavigationElement">
<a itemprop="url" href="#">
<span itemprop="name">Link 3</span>
</a>
</span>
</nav>
這樣做的結果的網址和名稱,都在同一組的名單,沒有一個單一的網址和名稱之間的任何關係。我認爲應該有一些方法來表明每個列表元素是一個具有一個URL和一個名稱的實體。 –
一般而言,你是對的,當然。但是正如我們在談論導航時,我假設這些鏈接都屬於一個整體,不是嗎? –