<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: XHTML and error handling</title>
	<atom:link href="http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/</link>
	<description>Web development and Internet trends</description>
	<pubDate>Tue, 07 Oct 2008 10:34:11 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.1</generator>
		<item>
		<title>By: Max Design - standards based web design, development and training &#187; Some links for light reading (29/6/05)</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-17573</link>
		<dc:creator>Max Design - standards based web design, development and training &#187; Some links for light reading (29/6/05)</dc:creator>
		<pubDate>Sun, 19 Nov 2006 09:34:23 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-17573</guid>
		<description>[...] Validity, Guidelines and Law 	A principled argument 	Accessibility Only For Disabilities? 	XHTML and error handling 	Matt Haughey - Bloggers on Blogging 	TS [...]</description>
		<content:encoded><![CDATA[<p>[...] Validity, Guidelines and Law 	A principled argument 	Accessibility Only For Disabilities? 	<acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> and error handling 	Matt Haughey - Bloggers on Blogging 	TS [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: (&#62;_&#60;) Doliaku &#124; el blog  &#187; Blog Archive   &#187; Â¿HTML o XHTML?</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-6163</link>
		<dc:creator>(&#62;_&#60;) Doliaku &#124; el blog  &#187; Blog Archive   &#187; Â¿HTML o XHTML?</dc:creator>
		<pubDate>Fri, 21 Jul 2006 15:07:40 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-6163</guid>
		<description>[...]  Kesteren Activating the Right Layout Mode Using the Doctype Declaration por Henri Sivonen XHTML and error handling por Robert Nyman 	 				 [...]</description>
		<content:encoded><![CDATA[<p>[...]  Kesteren Activating the Right Layout Mode Using the Doctype Declaration por Henri Sivonen <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> and error handling por Robert Nyman<br />
 				 [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: HTML Advisor &#187; HTML or XHTML?</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-2687</link>
		<dc:creator>HTML Advisor &#187; HTML or XHTML?</dc:creator>
		<pubDate>Wed, 18 Jan 2006 22:11:10 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-2687</guid>
		<description>[...] n Kesteren Activating the Right Layout Mode Using the Doctype Declaration by Henri Sivonen XHTML and error handling by Robert Nyman  	 	 					 	 	      	One Respo [...]</description>
		<content:encoded><![CDATA[<p>[...] n Kesteren Activating the Right Layout Mode Using the Doctype Declaration by Henri Sivonen <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> and error handling by Robert Nyman  	</p>
<p> 	One Respo [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Max Design - standards based web design, development and training  &#187; Blog Archive   &#187; Some links for light reading (29/6/05)</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-2379</link>
		<dc:creator>Max Design - standards based web design, development and training  &#187; Blog Archive   &#187; Some links for light reading (29/6/05)</dc:creator>
		<pubDate>Sun, 01 Jan 2006 21:10:21 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-2379</guid>
		<description>[...] Validity, Guidelines and Law 	A principled argument 	Accessibility Only For Disabilities? 	XHTML and error handling 	Matt Haughey - Bloggers on Blogging 	TSN.ca: Reloaded 	 [...]</description>
		<content:encoded><![CDATA[<p>[...] Validity, Guidelines and Law 	A principled argument 	Accessibility Only For Disabilities? 	<acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> and error handling 	Matt Haughey - Bloggers on Blogging 	TSN.ca: Reloaded 	 [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Robert Nyman</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-1550</link>
		<dc:creator>Robert Nyman</dc:creator>
		<pubDate>Sun, 06 Nov 2005 12:27:48 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-1550</guid>
		<description>Steve,

Well, its' ok; I rather think this was the place to post such a comment.

Regarding serving XHTML 1.0 as &lt;code&gt;text/html&lt;/code&gt; or &lt;code&gt;application/xhtml+xml&lt;/code&gt;, I can live with that. But I have to say it's disappointing to see so many using the Transitional doctype.</description>
		<content:encoded><![CDATA[<p>Steve,</p>
<p>Well, its&#8217; ok; I rather think this was the place to post such a comment.</p>
<p>Regarding serving <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> 1.0 as <code>text/html</code> or <code>application/xhtml+<acronym title="eXtensible Markup Language">XML</acronym></code>, I can live with that. But I have to say it&#8217;s disappointing to see so many using the Transitional doctype.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Steve Williams</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-1549</link>
		<dc:creator>Steve Williams</dc:creator>
		<pubDate>Sun, 06 Nov 2005 02:41:23 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-1549</guid>
		<description>Oops, sorry, meant to post in most recent HTML/XHTML article!</description>
		<content:encoded><![CDATA[<p>Oops, sorry, meant to post in most recent <acronym title="HyperText Markup Language">HTML</acronym>/XHTML article!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Steve Williams</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-1548</link>
		<dc:creator>Steve Williams</dc:creator>
		<pubDate>Sun, 06 Nov 2005 02:39:30 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-1548</guid>
		<description>Your post got me interested enough to look around some of the more popular *standardista* sites, and most I know of are using xhtml transitional doctypes, and none I visited (except Tommy's dead parrot) are serving as app xhtml/xml (according to Firefox Mac)?

A little disappointing?</description>
		<content:encoded><![CDATA[<p>Your post got me interested enough to look around some of the more popular *standardista* sites, and most I know of are using <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> transitional doctypes, and none I visited (except Tommy&#8217;s dead parrot) are serving as app <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym>/xml (according to Firefox Mac)?</p>
<p>A little disappointing?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Robert&#8217;s talk &#187; HTML or XHTML?</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-1497</link>
		<dc:creator>Robert&#8217;s talk &#187; HTML or XHTML?</dc:creator>
		<pubDate>Wed, 02 Nov 2005 21:27:58 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-1497</guid>
		<description>[...] en     Activating the Right Layout Mode Using the Doctype Declaration by Henri Sivonen     XHTML and error handling by Robert Nyman 							 				 						 	 	 		 		 		 [...]</description>
		<content:encoded><![CDATA[<p>[...] en     Activating the Right Layout Mode Using the Doctype Declaration by Henri Sivonen     <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> and error handling by Robert Nyman 							</p>
<p> [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Robert Nyman</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-784</link>
		<dc:creator>Robert Nyman</dc:creator>
		<pubDate>Tue, 23 Aug 2005 06:16:59 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-784</guid>
		<description>Splash!,

That was an interesting approach! Me myself I'm not sure  if the users should/are capable of making that decision or not. Many users just get scared away by messages about errors that require of them to make a call about what to do next.

Thanks for the tip about the &lt;acronym title="eXtensible markup Language"&gt;XML&lt;/acronym&gt; check class!</description>
		<content:encoded><![CDATA[<p>Splash!,</p>
<p>That was an interesting approach! Me myself I&#8217;m not sure  if the users should/are capable of making that decision or not. Many users just get scared away by messages about errors that require of them to make a call about what to do next.</p>
<p>Thanks for the tip about the <acronym title="eXtensible markup Language"></acronym><acronym title="eXtensible Markup Language">XML</acronym> check class!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Splash!</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-783</link>
		<dc:creator>Splash!</dc:creator>
		<pubDate>Mon, 22 Aug 2005 22:28:20 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-783</guid>
		<description>I think a good approach the browser developers could use is to show an error message but give options on what the user wants to do next. For example, it could say whatever error, and provide buttons for "View Page Anyway", "Go back" and anything else which would be worth doing. 

This way, it would allow the user to get to the information if it is important, but also make it clear something is not as it should be, thereby not promoting/allowing bad markup (ie. like HTML did).

Checking X(HT)ML for well-formedness on the server side is possible using PHP. I am currently writing it into my upcoming site. The xml check class at &lt;a href="http://phpxmlclasses.sourceforge.net/show_doc.php?class=class_xml_check.html" rel="nofollow"&gt;this site&lt;/a&gt; is useful, especially combined with the output control system in PHP, by using the callback function. It would allow you to check the markup before sending it out, and if there is a problem, you can send out a different friendly error page to the user (without well-formedness errors if this page is in XHTML too....!!).</description>
		<content:encoded><![CDATA[<p>I think a good approach the browser developers could use is to show an error message but give options on what the user wants to do next. For example, it could say whatever error, and provide buttons for &#8220;View Page Anyway&#8221;, &#8220;Go back&#8221; and anything else which would be worth doing. </p>
<p>This way, it would allow the user to get to the information if it is important, but also make it clear something is not as it should be, thereby not promoting/allowing bad markup (<acronym title="Internet Explorer">IE</acronym>. like <acronym title="HyperText Markup Language">HTML</acronym> did).</p>
<p>Checking X(HT)ML for well-formedness on the server side is possible using <acronym title="Hypertext PreProcessing">PHP</acronym>. I am currently writing it into my upcoming site. The <acronym title="eXtensible Markup Language">XML</acronym> check class at <a href="http://phpxmlclasses.sourceforge.net/show_doc.php?class=class_xml_check.html" rel="nofollow">this site</a> is useful, especially combined with the output control system in <acronym title="Hypertext PreProcessing">PHP</acronym>, by using the callback function. It would allow you to check the markup before sending it out, and if there is a problem, you can send out a different friendly error page to the user (without well-formedness errors if this page is in <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> too&#8230;.!!).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Robert Nyman</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-782</link>
		<dc:creator>Robert Nyman</dc:creator>
		<pubDate>Mon, 22 Aug 2005 09:41:55 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-782</guid>
		<description>bodaniel,

Yes, built-in validation in the server-side languages would be a nice thing. Of course you can build it yourself, load the output into some &lt;acronym title="eXtensible markup Language"&gt;XML&lt;/acronym&gt; object etc, but I for one would like it as an easier feature to use.</description>
		<content:encoded><![CDATA[<p>bodaniel,</p>
<p>Yes, built-in validation in the server-side languages would be a nice thing. Of course you can build it yourself, load the output into some <acronym title="eXtensible markup Language"></acronym><acronym title="eXtensible Markup Language">XML</acronym> object etc, but I for one would like it as an easier feature to use.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: bodaniel</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-778</link>
		<dc:creator>bodaniel</dc:creator>
		<pubDate>Mon, 22 Aug 2005 07:49:10 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-778</guid>
		<description>Robert,

I think the browser should display an error message if the XHTML isn't valid. The cryptical part of the error message would probably be "Unexpected element X found ..." or some other common validation error message. It would be nice if the main part of the error message was easily understood by all users. The user should also be told what he/she should do to get back to where he/she came from.

I don't think the browser should have to guess what the content of the invalid XHTML actually should have been.

One thing I really would like is a better XHTML validation support in server side scripting languages (eg JSP). The XHTML produced by the scripting language should automatically be validated while it is beeing generated and if the validation process finds an error the user should be redirected to my JSP error handling page where I, as a programmer, get the chance to find out about the error and can choose what to display for the user. If I am unable to output valid XHTML even on the error handling page, I suck. It might sometimes be a good idea to output HTML instead of XHTML on the error handling page.</description>
		<content:encoded><![CDATA[<p>Robert,</p>
<p>I think the browser should display an error message if the <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> isn&#8217;t valid. The cryptical part of the error message would probably be &#8220;Unexpected element X found &#8230;&#8221; or some other common validation error message. It would be nice if the main part of the error message was easily understood by all users. The user should also be told what he/she should do to get back to where he/she came from.</p>
<p>I don&#8217;t think the browser should have to guess what the content of the invalid <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> actually should have been.</p>
<p>One thing I really would like is a better <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> validation support in server side scripting languages (eg <acronym title="Java Server Pages">JSP</acronym>). The <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> produced by the scripting language should automatically be validated while it is beeing generated and if the validation process finds an error the user should be redirected to my <acronym title="Java Server Pages">JSP</acronym> error handling page where I, as a programmer, get the chance to find out about the error and can choose what to display for the user. If I am unable to output valid <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> even on the error handling page, I suck. It might sometimes be a good idea to output <acronym title="HyperText Markup Language">HTML</acronym> instead of <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> on the error handling page.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Robert Nyman</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-769</link>
		<dc:creator>Robert Nyman</dc:creator>
		<pubDate>Sun, 21 Aug 2005 09:17:42 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-769</guid>
		<description>Jim,

&lt;blockquote&gt;If you have to deal with other peopleâ€™s bad code, then XHTML is simply the wrong tool for the job.&lt;/blockquote&gt;
Yes and no. For me, to write valid code and then present the flaws to the people responsible also helps me in pushing them toward demanding more from their tools and the content providers.

I'm not sure an error parser would be the best thing, I don't know which approach would be the best. Hence the discussion. :-)
But, as Chris mentions about Opera (I haven't tested this myself), to show the error below while still displaying the web page sounds like a much better approach to me.

Chris,

Typos fixed, thank you. However, I'm not sure about what case errors you refer to?

bodaniel,

For a parser to go through valid &lt;acronym title="eXtensible HyperText Markup Language"&gt;XHTML&lt;/acronym&gt;, it should, theoratically, be faster than looking for optional tags.
But then we come back to those cases where the code isn't valid, and how the web browsers should handle that...</description>
		<content:encoded><![CDATA[<p>Jim,</p>
<blockquote><p>If you have to deal with other peopleâ€™s bad code, then <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> is simply the wrong tool for the job.</p></blockquote>
<p>Yes and no. For me, to write valid code and then present the flaws to the people responsible also helps me in pushing them toward demanding more from their tools and the content providers.</p>
<p>I&#8217;m not sure an error parser would be the best thing, I don&#8217;t know which approach would be the best. Hence the discussion. <img src='http://www.robertnyman.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /><br />
But, as Chris mentions about Opera (I haven&#8217;t tested this myself), to show the error below while still displaying the web page sounds like a much better approach to me.</p>
<p>Chris,</p>
<p>Typos fixed, thank you. However, I&#8217;m not sure about what case errors you refer to?</p>
<p>bodaniel,</p>
<p>For a parser to go through valid <acronym title="eXtensible HyperText Markup Language"></acronym><acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym>, it should, theoratically, be faster than looking for optional tags.<br />
But then we come back to those cases where the code isn&#8217;t valid, and how the web browsers should handle that&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: bodaniel</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-765</link>
		<dc:creator>bodaniel</dc:creator>
		<pubDate>Thu, 18 Aug 2005 19:04:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-765</guid>
		<description>Chris,
if you use javascript to update the XHTML you have to see to it that the javascript doesn't make the XHTML invalid.

I thought XHTML was the next step towards fast rendering browsers, that shouldn't have to guess what your messy HTML actually tries to say? If the browser has to fix every error in the XHTML document you would also need recommendations telling how errors in XHTML documents should be handled. Try to think of all possible errors that can occur and what the error handling code would look like. What should the browser do if it is within an ordered list and finds the end of a heading?</description>
		<content:encoded><![CDATA[<p>Chris,<br />
if you use javascript to update the <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> you have to see to it that the javascript doesn&#8217;t make the <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> invalid.</p>
<p>I thought <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> was the next step towards fast rendering browsers, that shouldn&#8217;t have to guess what your messy <acronym title="HyperText Markup Language">HTML</acronym> actually tries to say? If the browser has to fix every error in the <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> document you would also need recommendations telling how errors in <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> documents should be handled. Try to think of all possible errors that can occur and what the error handling code would look like. What should the browser do if it is within an ordered list and finds the end of a heading?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chris Hester</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-762</link>
		<dc:creator>Chris Hester</dc:creator>
		<pubDate>Mon, 15 Aug 2005 13:42:12 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-762</guid>
		<description>Tommy Olsson wrote:

&lt;blockquote cite="http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-591"&gt;But an XHTML document is static. It is not executed and modified in real-time, so there is no need for runtime exception handling.&lt;/blockquote&gt;

Not quite. A document can be altered many times after loading by JavaScript. A single error there may render a valid document invalid. Also the content of a frame might be refreshed, bringing new and possibly invalid code into the page. XHTML documents are, like HTML ones, dynamic.

This post interests me because I have just made a round of XML tests (see &lt;a href="http://www.designdetector.com/archives/05/08/XMLBrowserDifferences.php" title="" rel="nofollow"&gt;XML Browser Differences&lt;/a&gt;). I'm delighted to say that an error in an XHTML page only gives a blank yellow screen in one browser - Firefox. In Opera the document is parsed and displayed! (The error message appears underneath.)

What's more, IE6 also does the same, that is for XML documents. I was very surprised by this. Good news for the user, unless they use Firefox!

In my opinion, the browser should attempt to recover the document as far as possible, so at least something is displayed. After all, a single fault is not likely to affect the rest of the content enough to warrant not showing any of it at all. (Or perhaps I'm wrong in certain cases.) XHTML should therefore be no different than HTML. Browsers are now very good at fixing bad markup. Of course then we're left with the argument about encouraging such markup by the browser fixing errors.

By the way, you might want to fix those typo and case errors in the main post... :-)</description>
		<content:encoded><![CDATA[<p>Tommy Olsson wrote:</p>
<blockquote cite="http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-591"><p>But an <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> document is static. It is not executed and modified in real-time, so there is no need for runtime exception handling.</p></blockquote>
<p>Not quite. A document can be altered many times after loading by JavaScript. A single error there may render a valid document invalid. Also the content of a frame might be refreshed, bringing new and possibly invalid code into the page. <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> documents are, like <acronym title="HyperText Markup Language">HTML</acronym> ones, dynamic.</p>
<p>This post interests me because I have just made a round of <acronym title="eXtensible Markup Language">XML</acronym> tests (see <a href="http://www.designdetector.com/archives/05/08/XMLBrowserDifferences.php" title="" rel="nofollow"><acronym title="eXtensible Markup Language">XML</acronym> Browser Differences</a>). I&#8217;m delighted to say that an error in an <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> page only gives a blank yellow screen in one browser - Firefox. In Opera the document is parsed and displayed! (The error message appears underneath.)</p>
<p>What&#8217;s more, IE6 also does the same, that is for <acronym title="eXtensible Markup Language">XML</acronym> documents. I was very surprised by this. Good news for the user, unless they use Firefox!</p>
<p>In my opinion, the browser should attempt to recover the document as far as possible, so at least something is displayed. After all, a single fault is not likely to affect the rest of the content enough to warrant not showing any of it at all. (Or perhaps I&#8217;m wrong in certain cases.) <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> should therefore be no different than <acronym title="HyperText Markup Language">HTML</acronym>. Browsers are now very good at fixing bad markup. Of course then we&#8217;re left with the argument about encouraging such markup by the browser fixing errors.</p>
<p>By the way, you might want to fix those typo and case errors in the main post&#8230; <img src='http://www.robertnyman.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jim</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-760</link>
		<dc:creator>Jim</dc:creator>
		<pubDate>Mon, 08 Aug 2005 11:29:01 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-760</guid>
		<description>Faruk,

&#62; Itâ€™s the strictness of the syntax that promotes best practices tons better, not the actual tags/elements.

&#62; But HTML doesnâ€™t enforce you in any way to apply best practices to your code, whereas XHTML does.

Which best practices are enforced/promoted by XHTML served as text/html?

&#62; Nobody on the planet ever learned how to do XHTML right in one go. Neither did you. We all need to take things one step at a time, in this case that means learning XHTML one step at a time. You canâ€™t go expecting people to switch from old school, nested table-ridden, font tag-polluted HTML to clean, semantic, well-formed XHTML in one go. But thatâ€™s exactly what youâ€™re saying, and thatâ€™s very elitist of you.

Don't put words in my mouth.

If you have old-school, nested table-ridden, font tag-polluted HTML, then there are many intermediate steps you can take without switching to XHTML that will improve the quality of your code.

You don't have to switch to XHTML.  For the people who can't do XHTML right, there are no benefits.  If you switch to XHTML for the sake of "clean code" or "best practices", and you start writing invalid XHTML, then you've taken a step backwards, not forwards.  Pointing this out isn't elitist, it's using common sense.

XHTML isn't a club all the smart people join, it's a tool.  What I am saying is that you should use the right tool for the job.  For people who cannot do XHTML correctly, XHTML is the wrong tool for the job and HTML 4.01 is the right tool for the job.  How on earth is that elitist?

&#62; Keeping them at HTML will keep them away from promoting best practices effectively

How?  Does HTML prevent them from writing valid code?  No.  Does HTML prevent them from using CSS for layout?  No.  Does HTML prevent them from writing accessible pages?  No.  HTML is not incompatible with and doesn't discourage best practices.

Robert,

&#62; But to be clear, my scenario is often that I write and deliver valid code. Enter .NET-based CMS systems, third party content providers and other web developers/administrators that donâ€™t have the knowledge (or even interest) to do that.

If you have to deal with other people's bad code, then XHTML is simply the wrong tool for the job.

Jeroen,

&#62; I cannot get it into my head why anyone would want to enforce such a strict error handling.

Because web authors broke Postel's Law.  Because developers of authoring tools broke Postel's Law.  Postel's Law only holds up when both parties respect it.

Robert,

&#62; I think itâ€™s a huge difference. In those scenarios where the errors you mention occur, you (should) have proper error handling to show it gracefully to the end user. With application/xhtml+xml we donâ€™t get that option.

We don't get that option with JPEGs, GIFs, PNGs, MPEGs, or pretty much any other media type that is directly presented to the end-user without opportunity to catch errors.  Nobody's asked for a JPEG parser that can automatically recover from corrupt images.</description>
		<content:encoded><![CDATA[<p>Faruk,</p>
<p>&gt; Itâ€™s the strictness of the syntax that promotes best practices tons better, not the actual tags/elements.</p>
<p>&gt; But <acronym title="HyperText Markup Language">HTML</acronym> doesnâ€™t enforce you in any way to apply best practices to your code, whereas <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> does.</p>
<p>Which best practices are enforced/promoted by <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> served as text/html?</p>
<p>&gt; Nobody on the planet ever learned how to do <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> right in one go. Neither did you. We all need to take things one step at a time, in this case that means learning <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> one step at a time. You canâ€™t go expecting people to switch from old school, nested table-ridden, font tag-polluted <acronym title="HyperText Markup Language">HTML</acronym> to clean, semantic, well-formed <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> in one go. But thatâ€™s exactly what youâ€™re saying, and thatâ€™s very elitist of you.</p>
<p>Don&#8217;t put words in my mouth.</p>
<p>If you have old-school, nested table-ridden, font tag-polluted <acronym title="HyperText Markup Language">HTML</acronym>, then there are many intermediate steps you can take without switching to <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> that will improve the quality of your code.</p>
<p>You don&#8217;t have to switch to <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym>.  For the people who can&#8217;t do <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> right, there are no benefits.  If you switch to <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> for the sake of &#8220;clean code&#8221; or &#8220;best practices&#8221;, and you start writing invalid <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym>, then you&#8217;ve taken a step backwards, not forwards.  Pointing this out isn&#8217;t elitist, it&#8217;s using common sense.</p>
<p><acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> isn&#8217;t a club all the smart people join, it&#8217;s a tool.  What I am saying is that you should use the right tool for the job.  For people who cannot do <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> correctly, <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> is the wrong tool for the job and <acronym title="HyperText Markup Language">HTML</acronym> 4.01 is the right tool for the job.  How on earth is that elitist?</p>
<p>&gt; Keeping them at <acronym title="HyperText Markup Language">HTML</acronym> will keep them away from promoting best practices effectively</p>
<p>How?  Does <acronym title="HyperText Markup Language">HTML</acronym> prevent them from writing valid code?  No.  Does <acronym title="HyperText Markup Language">HTML</acronym> prevent them from using <acronym title="Cascading Style Sheets">CSS</acronym> for layout?  No.  Does <acronym title="HyperText Markup Language">HTML</acronym> prevent them from writing accessible pages?  No.  <acronym title="HyperText Markup Language">HTML</acronym> is not incompatible with and doesn&#8217;t discourage best practices.</p>
<p>Robert,</p>
<p>&gt; But to be clear, my scenario is often that I write and deliver valid code. Enter .NET-based <acronym title="Content Management System">CMS</acronym> systems, third party content providers and other web developers/administrators that donâ€™t have the knowledge (or even interest) to do that.</p>
<p>If you have to deal with other people&#8217;s bad code, then <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> is simply the wrong tool for the job.</p>
<p>Jeroen,</p>
<p>&gt; I cannot get it into my head why anyone would want to enforce such a strict error handling.</p>
<p>Because web authors broke Postel&#8217;s Law.  Because developers of authoring tools broke Postel&#8217;s Law.  Postel&#8217;s Law only holds up when both parties respect it.</p>
<p>Robert,</p>
<p>&gt; I think itâ€™s a huge difference. In those scenarios where the errors you mention occur, you (should) have proper error handling to show it gracefully to the end user. With application/xhtml+<acronym title="eXtensible Markup Language">XML</acronym> we donâ€™t get that option.</p>
<p>We don&#8217;t get that option with JPEGs, GIFs, PNGs, MPEGs, or pretty much any other media type that is directly presented to the end-user without opportunity to catch errors.  Nobody&#8217;s asked for a JPEG parser that can automatically recover from corrupt images.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Robert Nyman</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-684</link>
		<dc:creator>Robert Nyman</dc:creator>
		<pubDate>Mon, 18 Jul 2005 11:42:17 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-684</guid>
		<description>Gabriel,

Thanks for the suggestions!  :-)</description>
		<content:encoded><![CDATA[<p>Gabriel,</p>
<p>Thanks for the suggestions!  <img src='http://www.robertnyman.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gabriel Mihalache</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-682</link>
		<dc:creator>Gabriel Mihalache</dc:creator>
		<pubDate>Mon, 18 Jul 2005 09:54:28 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-682</guid>
		<description>Markdown and Textile can help. They output nothing but valid XHTML. More CMS should use them.</description>
		<content:encoded><![CDATA[<p>Markdown and Textile can help. They output nothing but valid <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym>. More <acronym title="Content Management System">CMS</acronym> should use them.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Robert Nyman</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-641</link>
		<dc:creator>Robert Nyman</dc:creator>
		<pubDate>Thu, 07 Jul 2005 14:24:06 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-641</guid>
		<description>Henrik,

That was at least five cents (as opposed to the normal two).  :-)

I think (read:hope) my reasons for using &lt;acronym title="eXtensible HyperText Markup Language"&gt;XHTML&lt;/acronym&gt; has been declared above and in Ben's post.

But sure, of course you're right in one sense: there's always people who jump on the bandwagon without knowing (or even caring) about the consequences.

Personally, I think everyone should go with what feels best for them, be it &lt;acronym title="eXtensible HyperText Markup Language"&gt;XHTML&lt;/acronym&gt; or &lt;acronym title="HyperText Markup Language"&gt;HTML&lt;/acronym&gt;. But I do recommend using a strict doctype no matter what your choice is.</description>
		<content:encoded><![CDATA[<p>Henrik,</p>
<p>That was at least five cents (as opposed to the normal two).  <img src='http://www.robertnyman.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>I think (read:hope) my reasons for using <acronym title="eXtensible HyperText Markup Language"></acronym><acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> has been declared above and in Ben&#8217;s post.</p>
<p>But sure, of course you&#8217;re right in one sense: there&#8217;s always people who jump on the bandwagon without knowing (or even caring) about the consequences.</p>
<p>Personally, I think everyone should go with what feels best for them, be it <acronym title="eXtensible HyperText Markup Language"></acronym><acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> or <acronym title="HyperText Markup Language"></acronym><acronym title="HyperText Markup Language">HTML</acronym>. But I do recommend using a strict doctype no matter what your choice is.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Henrik Lied</title>
		<link>http://www.robertnyman.com/2005/06/26/xhtml-and-error-handling/#comment-640</link>
		<dc:creator>Henrik Lied</dc:creator>
		<pubDate>Thu, 07 Jul 2005 13:56:03 +0000</pubDate>
		<guid isPermaLink="false">http://www.robertnyman.com/?p=94#comment-640</guid>
		<description>I don't like XHTML at all.
Every well-informed web-developer I know has realized that XHTML has become a childish markup language.

Seriously, how many of you aren't using XHTML - just because of the `cool` little X in front, or maybe because it's required to end elements without end-tags?

If you're not in the section above, you probably like the `strictness` which XHTML gives you.
Well then, why not just use a &lt;a href="http://www.cs.tut.fi/~jkorpela/html/my401.dtd" rel="nofollow"&gt;stricter &lt;abbr&gt;DTD&lt;/abbr&gt;&lt;/a&gt; of HTML 4.01?

I for my sake at least don't understand why someone would go through the haze of content-neogation, just to get an error-handler which destroys the site if containing errors.

I used XHTML before. But at the same time I like to give my commentators full HTML possibilities.
And when someone with too little HTML experience came in and wrote a comment, the whole site crashed.
I would much more like to have a non-valid HTML document, than having a XHTML document that won't display because it contain errors.

So my five cent: If you don't have any need for XHTML in form of MathML etc..: Don't use it ;)</description>
		<content:encoded><![CDATA[<p>I don&#8217;t like <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> at all.<br />
Every well-informed web-developer I know has realized that <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> has become a childish markup language.</p>
<p>Seriously, how many of you aren&#8217;t using <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> - just because of the `cool` little X in front, or maybe because it&#8217;s required to end elements without end-tags?</p>
<p>If you&#8217;re not in the section above, you probably like the `strictness` which <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> gives you.<br />
Well then, why not just use a <a href="http://www.cs.tut.fi/~jkorpela/html/my401.dtd" rel="nofollow">stricter <abbr><acronym title="Document Type Definition">DTD</acronym></abbr></a> of <acronym title="HyperText Markup Language">HTML</acronym> 4.01?</p>
<p>I for my sake at least don&#8217;t understand why someone would go through the haze of content-neogation, just to get an error-handler which destroys the site if containing errors.</p>
<p>I used <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> before. But at the same time I like to give my commentators full <acronym title="HyperText Markup Language">HTML</acronym> possibilities.<br />
And when someone with too little <acronym title="HyperText Markup Language">HTML</acronym> experience came in and wrote a comment, the whole site crashed.<br />
I would much more like to have a non-valid <acronym title="HyperText Markup Language">HTML</acronym> document, than having a <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> document that won&#8217;t display because it contain errors.</p>
<p>So my five cent: If you don&#8217;t have any need for <acronym title="eXtensible HyperText Markup Language - HTML reformulated as XML">XHTML</acronym> in form of MathML etc..: Don&#8217;t use it <img src='http://www.robertnyman.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /></p>
]]></content:encoded>
	</item>
</channel>
</rss>
