|XP is just a number|
(tye)Re: Larry vs. Joel vs. Ovidby tye (Sage)
|on Nov 21, 2001 at 01:07 UTC||Need Help??|
If it was agreed from day one that Web browsers weren't going to put up with sloppy HTML, then we wouldn't have the mess we have today.
And we might not have the popularity of the web we have today. Graceful failure is a good idea. Under your scheme all of the poor surfers of the world would be getting lots of errors from their browsers when those surfers have no control (and virtually no influence) over getting those errors fixed and many of them would have no idea what those errors mean.
The fact is that many decided to take advantage of one half of a sound principle by completely ignoring the other half of the principle. And only having one half of that principle is certainly not a good idea.
But putting the error checking and enforcement into a web browser client is a really bad idea. Error checking and enforcement needs to be as early in the process as possible. A much better idea would be to fix web servers so that they refuse to emit bad HTML rather than "fix" web browsers so that they refuse to display bad HTML!
It is a good idea to be at least somewhat lenient in what you accept. It is also a good idea to note cases where you were lenient in such a way that this information is likely to make its way back to the source. That back channel is often quite difficult to implement well. But a really horrible idea for such an implementation would be browsers giving errors to web surfers.
Now, being vague about what you accept is a bad idea. That is why the two halves need to go together. In order to be strict about what you provide, you have to define things clearly. Without that side of the coin, just being liberal about what you accept is trying to DWIM, which is (often) a nice feature of Perl but is usually a bad idea in any software that isn't interacting directly with a human.
And do you want to be responsible for explaining to the client that the $30,000 transaction couldn't go through because something changed how much whitespace is sent?
You can go too far in either direction. The idea of the principle is to prevent you from going too far in one direction. You are (in part) complaining about people going too far in the other.
But the complaint about browsers being too lenient is a bad form of wishful thinking. No one will ever produce a browser that is not lenient in what it accepts -- well, if they do, it won't get used much. Now a browser that tells you that it had to be lenient has its advantages, all of which are of no use (and some distraction) to the average web surfer and so will never become widely popular. And having some magical control to force all browsers to not be lenient or to at least complain loudly when they are force to be is, in fact, a very bad idea, unless you also design a way for those browsers to direct their loud complaints back at the authors of the bad HTML.
Go design that back channel first and then you can think about tilting against the "bad, lenient browser" windmill again.- tye (but my friends call me "Tye")