DOCTYPE
It seems people are just using XHTML because it has a “stricter” DOCTYPE
than HTML. (They are also quoting inferior notes from the W3C.) I personally believe that’s a terminology confusion as it’s not stricter, it just has fewer exceptions to the basic set of rules. Also, the W3C uses strict to denote the allowed set of elements for a particular DOCTYPE
, nowhere it uses it to symbolize the rules for optional end tags, et cetera or XML based parsing.
People don’t really like the draconian error handling, it’s bad for business as they know you can’t guarantee being well-formed on sites. Well, not today. Especially not on larger sites that aren’t based on an XML backend but on some string based template system with a crappy CMS.
If the DOCTYPE
is the only advantage — not that DOCTYPE
s matter — why not use a ‘stricter’ HTML 4.01 Strict DTD?
Oh and why is the blog in HTML 4.01 and the comments still asking for XHTML, Anne...?
"People don’t really like the draconian error handling"
That's a big generalisation, Anne. I for one like it a lot.
@1, if I'm not mistaken it's like transformed to minimalistic HTML 4.01 on the fly while generating the page and is in the backend as XHTML.
Psychological factor. Also, stricter syntax - it's bull to say that it's not really stricter, because it is stricter. The XML syntax is simply a strict syntax whereas SGML is an inherently non-strict syntax.
I'm perfectly happy with XHTML, knowing that sometime in the future it will probably be the norm, parsed correctly in all browsers.
Who cares if most of the population is actually viewing a html document because their browser is so crap? They don't.
Indeed, as BOK said, why if HTML is so nice use XHTML in your comments?
From a programmers view it's quite simple:"It's easier to parse"!
That is one of the reasons why I still write my pages in XHTML(with content negotiation) and not in HTML. It's still choosing beteen 2 bads, and I chose mine...
Oh and why is the blog in HTML 4.01 and the comments still asking for XHTML, Anne...?
Because Anne wants a weblog with a well-formed backend.
Doesn't "fewer exceptions to the basic set of rules" MEAN an increased sense of strictness???
I wouldn't mind a well-formed backend myself.
I use XHTML because then any old XML parser (including XSLT processors) can grab my information and use it however they want to without me dictating a limitation or a needless complexity to the user.
So, what you said, isn't the ONLY reason people are just using XHTML.
And even if XHTML has a stricter DOCTYPE
, does that really make much of a difference? Isn't the web really in worse shape because of all of the tagsoup?
"Because HTML allowed that to happen", is what you'll say. That is true, but XHTML doesn't particularly get rid of tagsoup, either: You could easily make a valid XHTML document with nested tables for layout and CLASS
attributes like gray-background and big-text. And sending XHTML as text/html
doesn't make it conform to the strictness of XHTML, anyway.
Just a few thoughts.
"That is true, but XHTML doesn't particularly get rid of tagsoup, either: You could easily make a valid XHTML document with nested tables for layout and CLASS attributes like gray-background and big-text."
But that's not tag soup. It's (arguably, case-dependent) bad form.
BOK, because I love contradiction. Also, making it easier for people to comment might attract spammers and such. Not good.
Hayo, me too. Just not client-side. (Client applies to potential visitors as well as the browser here.)
Faruk, for all ‘bigger’ projects I have done so far there was no such thing as a psychological factor.
Devon, you and your dog might have a different reason, but minorities don’t count for the moment. Also if you don’t run it through Tidy or so first your are fucked anyway.
But that's not tag soup. It's (arguably, case-dependent) bad form.
Ah, yes, thanks for the correction. As you said, though, it is bad form. And that is point I am trying to make (the key word being "bad"): If people can fudge things (and think it's okay), they will fudge things (and think it's okay). We need to be fighting for semantics and logical document structure. The lack of these qualities have made the web what it is today.
"People don’t really like the draconian error handling"
That's a big generalisation, Anne. I for one like it a lot.
Count me in on the draconian handling lovers.
I prefer to build things as end-to-end XML toolchains, and then draconian handling is, IMHO, great. Of course, that part is in no real disagreement with Anne’s post.
Doesn't "fewer exceptions to the basic set of rules" MEAN an increased sense of strictness???
Absolutely. However, Anne's point is that what's stricter is not the document type. Though the HTML 4.01 and XHTML 1.0 document types are not exactly the same, the latter aren't particularly more strict than the former. What's stricter is the syntax.
Mind you in SGML the document type can dictate many aspects of syntax strictness, but that's not really all that relevant since HTML is only really SGML in theory.
In any case the point is that XHTML 1.0 is stricter than HTML in syntax only because it is XML. When you take XML out of the equation by not parsing the document as XML, XHTML is in no way stricter---and that's a damned good thing, given the current nature of the Web.
Well, I was not entirely truthful in my last statement. XHTML is actually stricter in some significant ways, but it's all things that most people using XHTML-as-HTML are not aware of anyway, so the actual differences in the document type are totally lost on most people.
In other words, although XHTML 1.0 document types are kind of stricter in a couple of ways, it's not in the ways people who think they are stricter usually think they are, so their arguments are bunk.
All those people who use XHTML incorrectly have at lease made the effort to do the 'right thing' even if they don't understand it yet. Give them a chance and they will come through, its all about learning.
I may be wrong, but from what I've heard, XHTML isn't stricter than HTML, it just has a simpler syntax. Yes, simpler, since it allows for less deviation. It is (arguably) easier to code for, since you have less options when you're coding for it.
Less options; well maybe if you don't consider eXtensbilty or multi namespaces, etc. and consider only plain vanilla XHTML 1.0 then yes well-formedness is probably easier for the author to learn.
And lets face it, how often does that extensibility need to be used?
No, Anne, I don't think you really understood what I said in that article. You try to translate it back again into technological terms, and that is not doing justice to my arguments.
XHTML demands and promotes better coding standards than HTML. It is not about the strictness of the doctype. HTML allows for more deviation from the norm, and most of it ugly. That's why I say that for me as a coder, it is more for psychological reasons: it is about the beauty of the code and the desirability of the coding standards that go with it.
The reason for going with Appendix C is a practical matter. I agree it would be more desirable to use XML tools from beginning to end, but hey, we live in an imperfect world.
And lets face it, how often does that extensibility need to be used?
At the moment it's more a question of how often can that extensibility be used. When the answer to that changes from "almost never" we should start seeing interesting uses.
And lets face it, how often does that extensibility need to be used?
We’d see more like this if the extensibility really was useful in practice. What I’m particularly curious to see is what happens when SVG achieves significant browser support…