[webkit-dev] HTML5 & Web Links (RFC 5988)

Alexey Proskuryakov ap at webkit.org
Wed Nov 10 09:12:56 PST 2010


10.11.2010, в 01:59, Alex Milowski написал(а):

>> Moving or copying essential information about a document into HTTP headers is frustrating for charset declarations, why do that for anything else? With charsets, there is at least the explanation that many text formats don't have a place to declare it internally.
>> 
> 
> The charset parameter on the content-type header is more reliable than
> what is in the document.  

If you meant that it is authoritative, then yes, that's how it works.

On the other hand, it's certainly not reliable. If you move your content to a different server, or just download it to a local file, the information is lost.

> It also gives you a way to know how to
> decode the bytes into a character stream before you look into those
> bytes.  

Yes, knowing charset in advance certainly simplifies things. But since it cannot always be present, clients need to have code that checks for charset declaration in content anyway.

> In this way, it is very unlike the reservations some might have for
> the Link header.


I think that issues are the same - but as mentioned before, charset in HTTP headers is necessary for some types of content, and that's a good excuse for its existence. Link doesn't appear to ever be necessary.

- WBR, Alexey Proskuryakov



More information about the webkit-dev mailing list