Content Negotiation for HubMed Tags

·

A couple of months ago, SIMILE's Piggy Bank was fixed so that it sends 'application/rdf+xml' in the HTTP Accept headers when it requests data. This means that sites can produce HTML or RDF/XML at the same URL, but decide which to output based on each request (e.g. web browsers using Accept headers that have 'text/html' at a higher priority than 'application/rdf+xml' will receive the HTML version).

I've added this content negotiation to most of HubMed's Tag Storage pages, so all of this data can now be imported easily into tools like Piggy Bank.

As a workaround for agents like NetNewsWire that don't send any Accept headers, even though they require RDF/XML rather than HTML, appending ?format=rdf to a URL will be treated as a request for 'application/rdf+xml'.