[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: The type attribute and HTTP content negotiation.




Dare Obasanjo wrote:


How does ATOM deal with the following issue originally
posted at http://www.dionidium.com/2003/12/atom-03


"One particular change to Atom has left us perplexed.
Previously, Atom <link> tags contained only a
resource's address, with no attributes, like this:

<link>http://www.example.com/</link>

The new format requires the type attribute, which
lists the target document's media type, like this:

<link rel="alternate" type="text/html"
href="http://www.example.com/"/>

As regular readers know, we're serving our documents
as 'application/xhtml+xml' to browsers that support it
and 'text/html' to those that don't. There's no way to
tell from our Atom feed which media type your browser
will get. As a result, we're not sure which media type
to use in our feed's <link> tags (or if it even
matters). Let us know what you think.".

With conneg, you can find multiple media types in the same location. Stating that xhtml can be found at a given URI does not imply that one can not find other representations at the same location.


What a link tag says is literally "you can find THIS media type THERE". This means that it would be quite valid to have multiple link statements with the same URI.

- Sam Ruby