[Top][All Lists]

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

Re: [Lynx-dev] Re: progress on dev.10

From: Thomas Dickey
Subject: Re: [Lynx-dev] Re: progress on dev.10
Date: Thu, 11 Sep 2008 06:57:14 -0400 (EDT)

On Thu, 11 Sep 2008, David Dorward wrote:

Thomas Dickey wrote:
9j/9k look at this line

    <?xml-stylesheet href="/ve.css" type="text/css"?>

and because it's saying that it's xml without specifying a charset,
assumes it's UTF-8.
That line says "Link a stylesheet to this XML document". It doesn't
specify that it is XML at all (although you might imply that from that

The fact that there is no XML prolog at all would imply that it was
UTF-8 (since that is the default), but the document is being served as
text/html, so tag soup slurping rules apply.

(Incidentally, Appendix C (a non-normative, fuzzily written part of the
spec that is a requirement of serving XHTML as text/html ) says that the
style declaration should not be present, since it is a processing
instruction: )

HTTP defaults for ISO-8859-1 for text/* documents which don't specify
 However, I see the following

<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1" />
Ah, the wonder that is "http-equiv".

Here is what the spec has to say on the subject:

   "This attribute may be used in place of the name attribute. HTTP
   servers use this attribute to gather information for HTTP response
   message headers."

Yup, it is for servers, not clients. Guess what though? Other clients do
pay attention to it, and a significant number of sites depend on it.


Basically, the whole issue is underspecified and suffers from browsers
paying attention to things they should ignore, recovering in interesting
ways, and having wonderful conflicts when there are multiple ways to
specify the same thing, some of which apply differently depending on the
HTTP headers served up.

I haven't looked at it in detail, but the HTML5 draft is likely to give
the safest (i.e. most consistent with everything else) approach to
dealing with character encoding (at least in text/html):

I was reading the HTML5 draft this week, and startled to see that it discards the DTD portion of the DOCTYPE. That will make interoperability interesting...

(thanks for the feedback)

Thomas E. Dickey

reply via email to

[Prev in Thread] Current Thread [Next in Thread]