It would be nice if the GeoShape page included examples or the individual properties were broken out instead of just being Text.
I'm specifically interested in the circle property. I want to define a circle of 20 mile (~ 32km) radius from Nottingham City Centre (52.953, -1.149).
<!DOCTYPE html>
<html>
<head>
<title>Nottingham City Neighbourhood</title>
</head>
<body>
<div itemscope itemtype="http://schema.org/Place">
<div itemprop="geo" itemscope itemtype="http://schema.org/GeoShape">
<meta itemprop="circle" content="52.953 -1.149 32186.88"/>
</div>
</div>
</body>
</html>
The rich snippet tool does pick out the data, but I don't trust that I've used the right format. Especially since the parsed longitude is positive.
> The following structured data is viewable only in the XML results view
> in Custom Search. More information.
>
> geoshape (source = MICRODATA) circle = 52.953 -1.149 32186.88
>
>
> The following structured data can be used to filter search results in
> Custom Search. More information.
>
> more:pagemap:geoshape more:pagemap:geoshape-circle
> more:pagemap:geoshape-circle:1.149
> more:pagemap:geoshape-circle:32186.88
> more:pagemap:geoshape-circle:52.953
> more:pagemap:geoshape-circle:52.953_
As for the others, I think both box and polygon would be in the format "$lat1,$long1 $lat2,$long2 $lat3,$long3 $lat1,$long1" for a square.
Anybody have a definitive answer or reason?
I've done some archaeology, following a similar trail to others.
Details: http://lists.w3.org/Archives/Public/public-vocabs/2012Jun/0116.html
The compounding confusion seems to be (as Yves Martin points out) missing whitespace in the original rNews examples.
We'll get this situation improved and I'll report back here.
Validation
The example you give (in the first version of your question) does not pass validation at http://validator.nu/. You cannot use directly a property in the same node that declares the entity type. Probably the rich snippet tool is not strict enough. To confirm, this alternate tool also refuses to generate a JSON expression from your block because of the lack of a top level element.
So an additional node is required for the geo
property, here is a proper way to express it (doctype and title are for validation tool only):
<!DOCTYPE html>
<title>Nottingham City Neighbourhood</title>
<div class="hidden" itemscope itemtype="http://schema.org/GeoShape">
<div itemprop="geo">
<meta itemprop="circle" content="52.953 -1.149 32186.88"/>
</div>
</div>
Recommendation
According to this Google FAQ only few entities are really supported and based on Organization and Event examples in microdata format, the optional geo
property only propose longitude
and latitude
elements from http://schema.org/GeoCoordinates. So there is less doubt to use that simple point definition compared to circle
. By the way this example is valid and properly extracted:
<div itemscope itemtype="http://data-vocabulary.org/Organization">
<span itemprop="name">Nottingham City Neighbourhood</span>
<div itemprop="geo">
<meta itemprop="circle" content="52.953 -1.149 32186.88"/>
</div>
</div>
If you use sindice.com, there is no hit for http://schema.org/GeoShape
whereas http://schema.org/GeoCoordinates
is extensively used. Not so easy to find real world usage of circle
.
Circle property value
For the circle property content itself, many documentation refers to WGS84 but it only concerns point. This documentation confirms the content text structure for the circle
element.
This example for rNews obviously lacks a space before the 500 radius and is not properly rendered, the page source contains <td class="rnews_td codestyle">38.920952 -94.645443500</td>
instead of <td class="rnews_td codestyle">38.920952 -94.645443 500</td>
You should look at schema generators or parsers. Maybe one of them has implemented a fine grain editor for GeoShape properties instead of a raw text field, so that you can confirm property content structure. I have looked at Any23 but still the same issue: GeoCoordinates is implemented but not GeoShape.
Box and polygon property value
No coma is expected between longitude and latitude values for point, box, polygon or line (only use space) according to both rNews and GeoRSS.
As a conclusion, you should avoid GeoShape
if your aim is to provide a location to search engines... At the moment, only GeoCoordinates
seems to be a reasonable choice.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With