- /documents/juggling_rdfa_google_rich_snippet
Topic Maps Lab juggling RDFa for Googles 'Rich Snippets'
Erstellt von Michael Prilop und Marcel Hoyer am 06.08.2009 und aktualisiert am 12.08.2009.
Abstract:
With Google introducing rich snippets into their search results we had a good reason to enrich our site with RDFa markup thereby semantically anotating our data publicly available.
Google is now starting to not only show short snippets - a sample of a webpage’s content - but also so called Rich Snippets in their search results.
Rich Snippets give users convenient (semantically augmented) summary information about their search results at a glance.
Until now we stored loads of information in our Topic Map for this portal but exporting it in whole to the public would have been no good example of dealing with data privacy :)
So why not make the information which is available publicly anyway a bit easier readable for those machines under us? We did so for topicmapslab.de. And hope that these snippets will be used to improve search results. Here is a small snippet from our view which produces a person’s page. More information about using RDFa markup is available on google or RDFa wiki.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.0//EN" "http://www.w3.org/MarkUp/DTD/xhtml-rdfa-1.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="http://rdf.data-vocabulary.org.html#" ...
You would want to choose a appropriate doctype first and define the prefixes used.
<div class="detailShape" typeof="v:Person"> <%= image_tag(url_for_file_column(person, "thumbnail", "detail"), "property"=>"v:photo")%> <h1 property="v:name"><%=h person.full_name -%></h1> <br/><span rel="v:address"><%= t(:"address") + ":" -%><br/> <%= render_shape :for => person.address, :shape => "card" -%><br/><br/> </span> ...
In your views just explicitly markup the data you want to highlight.
Yes it is as easy as that! From now on any search engine will be able to use your semantically enriched content for a better search.
Autoren
Michael Prilop
prilop@informatik.uni-leipzig.de
Michael ist beteiligt an Topic Maps Lab Community.. und Maiana. Er ist Autor von Maiana - a social Topic Maps.. .
Marcel Hoyer
http://pixelplastic.de/
Marcel ist Projektleiter von SharpTM. Er ist beteiligt an TMAPI.Net, Topic Maps Lab Community.. und Maiana. Marcel ist Autor von Maiana - a social Topic Maps.. .
Thematik
Topic Maps Lab Community Portal
Topic Maps driven web application
A new Topic Maps community portal, which based on Topic Maps technologies.