Sunday, November 14, 2004

Serving XHTML as 1.1 or 1.0

Serving XHTML as 1.1 or 1.0 from Articles at Aboho
A very important aspect which some people may not even realize, as I have seen on multiple Websites, is that XHTML 1.1 must, must be served as an XML document. This means, when you see the page info of an XHTML 1.1 document, you should never see the MIME type text/html. Therefore, when using PHP on the backend (or any server-side language), you must provide the correct MIME type which is: application/xhtml+xml. However, a major problem to this, is that IE doesn't support this MIME type at all and will try and download the file instead of displaying the page.....

No comments: