Fluoresce Posted September 3, 2014 Share Posted September 3, 2014 Probably a stupid question . . . The MIME type in my php.ini file is set to text/html: default_mimetype = "text/html" But, because I use XHTML 1.0 Strict, the MIME type of my web pages is set to text/xml: <meta http-equiv="content-type" content="text/xml; charset=utf-8" /> I should therefore change the php.ini MIME type to text/xml, right? Quote Link to comment Share on other sites More sharing options...
Fluoresce Posted September 4, 2014 Author Share Posted September 4, 2014 My header says: Content-Type: text/html; charset=utf-8 even though my meta tag says: <meta http-equiv="content-type" content="text/xml; charset=utf-8" /> Quote Link to comment Share on other sites More sharing options...
jazzman1 Posted September 4, 2014 Share Posted September 4, 2014 No, it's not really about the Doctype declaration. You can set dynamically the content of the html meta tag by php or just, use a static html: <meta http-equiv="content-type" content="text/html;charset=utf-8" /> Quote Link to comment Share on other sites More sharing options...
Jacques1 Posted September 4, 2014 Share Posted September 4, 2014 The browser ignores the meta element if you've already declared the content type with an HTTP header. In your case, the element only takes effect if the user downloads the document and opens it offline. But using two different content types is of course a bad idea. I generally have no idea why you insist on this exotic XHTML stuff, but that's a different story. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.