W3C home > Mailing lists > Public > public-xhtml2@w3.org > September 2008

Getting XHTML into Internet Explorer while using application/xhtml+xml

From: Steven Pemberton <steven.pemberton@cwi.nl>
Date: Mon, 29 Sep 2008 16:49:55 +0200
To: "tina@greytower.net" <tina@greytower.net>
Cc: "XHTML WG" <public-xhtml2@w3.org>
Message-ID: <op.uh8zhhgpsmjzpq@acer3010.lan>

Hi Tina,

I had an action item to get you examples of delivering XHTML to IE while  
using application/xhtml+xml.

Sorry it took so long, I had to do some digging, and use a different  
machine, since I have a filter on my main machine that accepts  
application/xhtml+xml anyway.

So, I first discovered that it was possible by mistake. I couldn't work  
out why I could see

	http://www.w3.org/International/tests/sec-ruby-markup-1.html

even though it claimed it was being sent as application/xhtml+xml (and  
that checked out in Opera, where you can request that sort of information).

Other examples of application/html+xml documents working in IE are at
	http://www.w3.org/MarkUp/Test/xhtml-print/current/

All the tests are served as application/xhtml+xml.

But try http://www.w3.org/International/tests/sec-ruby-markup-1 (which  
just serves the same file) and IE will give you the download dialogue, and  
modern browsers will display it. So the .html (and .htm in the xhtml-print  
tests) do make a difference to IE.

So my conclusion: it is done with URL sniffing and content sniffing (which  
is why you can serve html as text/plain as well if the urge takes you). I  
think if the URL matches then IE will sniff the content, and for IE that  
means (I seem to remember) looking for <title> in the first 256 (512?)  
characters of the file.

For the URL sniffing, it used to be possible to just append "?.html" to a  
URL, but that doesn't seem to work anymore.

See also:
http://blogs.msdn.com/ie/archive/2005/02/01/364581.aspx
http://blogs.msdn.com/ie/archive/2008/07/02/ie8-security-part-v-comprehensive-protection.aspx

Hope this helps,

Steven
Received on Monday, 29 September 2008 14:50:47 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 23 February 2010 18:12:49 GMT