If a browser with a User-Agent containing MSIE requests a .html file,
change its Content-Type to text/html (because application/xhtml+xml works
in all other browsers):
RewriteEngine on
RewriteCond %{HTTP_USER_AGENT} .*MSIE.*
RewriteCond %{REQUEST_URI} \.html$
RewriteRule .* - [T=text/html]
-
If a client requests an XHTML file, it says to do normal
content-negotiation. If the client's HTTP Accept header says they like
text/html more, send them that. If it says they like application/xhtml+xml
more, send them that.
Fine. I have even done that successfully with two different files.
So it's not possible to serve one file with two different Content-Types,
and you think that is as it should be?
Did you read the part about why XHTML should be served to some clients as
text/html, and others as application/xhtml+xml?
application/xhtml+xml is the correct Content-Type for xhtml.
I moved this bit to the top because I think it makes everything else
irrelevant:
Note however that old browsers who do not understand the type
application/xhtml+xml, are *really* old.
Note also that no matter what the server sends as Content-Type header,
if the browser is IE, it will