html - Breadcrumbs on current page -


i have implemented breadcrumbs this:

<div itemscope itemtype="http://data-vocabulary.org/breadcrumb">     <a href="home url" itemprop="url">         <span itemprop="title">home title</span>     </a> >  </div> <div itemscope itemtype="http://data-vocabulary.org/breadcrumb">     <a href="1st level url" itemprop="url">         <span itemprop="title">1st level title</span>     </a> >  </div> <div itemscope itemtype="http://data-vocabulary.org/breadcrumb">     <span itemprop="title">current title</span> </div> 

as can see, haven't specified url current page, redundant. when try google testing tool, error saying url missing current page breadcrumb.

given that, have 3 options can think of.

i specify url current page:

<div itemscope itemtype="http://data-vocabulary.org/breadcrumb">     <a href="home url" itemprop="url">         <span itemprop="title">home title</span>     </a> >  </div> <div itemscope itemtype="http://data-vocabulary.org/breadcrumb">     <a href="1st level url" itemprop="url">         <span itemprop="title">1st level title</span>     </a> >  </div> <div itemscope itemtype="http://data-vocabulary.org/breadcrumb">     <a href="current level url" itemprop="url">         <span itemprop="title">current title</span>     </a> </div> 

i display current page title without including in structured data markings:

<div itemscope itemtype="http://data-vocabulary.org/breadcrumb">     <a href="home url" itemprop="url">         <span itemprop="title">home title</span>     </a> >  </div> <div itemscope itemtype="http://data-vocabulary.org/breadcrumb">     <a href="1st level url" itemprop="url">         <span itemprop="title">1st level title</span>     </a> >  </div> <span>current title</span> 

i don't display current level in breadcrumbs (i don't want must say):

<div itemscope itemtype="http://data-vocabulary.org/breadcrumb">     <a href="home url" itemprop="url">         <span itemprop="title">home title</span>     </a> >  </div> <div itemscope itemtype="http://data-vocabulary.org/breadcrumb">     <a href="1st level url" itemprop="url">         <span itemprop="title">1st level title</span>     </a> </div> 

what think it's best should do?

the solution use <meta> tag.

so, last item in breadcrumb should this:

<div itemscope itemtype="http://data-vocabulary.org/breadcrumb"> <span itemprop="title">current title</span> <meta itemprop="url" content="current url" /> </div>

this validate on google testing tool , achieve desired goal construct valid breadcrumb without "displaying" redundant link.

for reference: getting started schema.org using microdata

3c. missing/implicit information: use meta tag content

sometimes, web page has information valuable mark up, information can't marked because of way appears on page... in these cases, use meta tag along content attribute specify information.

have add sake of completeness have formatted breadcrumb google serp, according current specs, example code should this:

<div itemscope itemtype="http://data-vocabulary.org/breadcrumb" id="a" itemref="b"> <a href="home url" itemprop="url"> <span itemprop="title">home title</span> </a>  </div> <div itemscope itemtype="http://data-vocabulary.org/breadcrumb" id="b" itemprop="child" itemref="c"> <a href="1st level url" itemprop="url"> <span itemprop="title">1st level title</span> </a> </div> <div itemscope itemtype="http://data-vocabulary.org/breadcrumb" id="c" itemprop="child"> <span itemprop="title">current title</span> <meta itemprop="url" content="current url" /> </div> 

bear in mind google breadcrumb documentation due review shortly, since seems that, @ last, google has adopted schema.org markup breadcrumbs can inferred "better presentation of urls in search results" post in official google webmaster central blog , discussion on it.


Popular posts from this blog

c# - ODP.NET Oracle.ManagedDataAccess causes ORA-12537 network session end of file -

matlab - Compression and Decompression of ECG Signal using HUFFMAN ALGORITHM -

utf 8 - split utf-8 string into bytes in python -