Google Rich Snippets and Facebook Open Metagraph I want to implement support for Google Rich Snippets to show author info and fivestar ratings in Google's search engine results pages. I also want to be able to support Facebook's Open Graph to have Facebook pick the correct image when a node with an image is "liked" or embedded on Facebook.

Looks like I can use Schema.org, microdata or RDFx modules. I also came across a post suggesting to just use a preprocess hook.

The schema.org module doesn't seem to support fivestar ratings. Microdata is relatively new and I'm a bit confused about the RDFX module.

Does anyone have experience with this?
In the answer above, there are modules indicated. However, in my experience, they won't work with fivestar, for they are only generic. So, what I usually do in such cases, is to:


Create a template for that node type, like node--type.tpl.php
Create a preprocess function in your theme's template.php file, implementing hook_preprocess_HOOK(). This will translate to an actual function name like mytheme_preprocess_node(&amp;Svariables).
In that function, use the $variables['node'] to get the data from the fivestar widget field.
Format and prepare that data for output, and add your custom variables to the $variables array.
Use the variables you provided in your preprocess function to insert the correct markup in your node file to correspond to the opengraph / rich snippets format.


Some notes: 


Use devel module and dpm() function to dump the $variables in preprocess function and the data in the template file.
Use the google markup tool and the facebook markup tool to test your markup.
The logic is, prepare variables in preprocess, and put them in markup in template file. Try not to have computations (business logic) in the template file itself, use preprocess for it.