By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,500 Members | 1,250 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,500 IT Pros & Developers. It's quick & easy.

mime types in Apache and the validator

P: n/a
Hi all,

First of all, this is probably a little OT here, please point me to a
better place if you deem that appropriate.

My website (see sig) validates fine, but with one annoying warning:

The document is being served with the text/html Mime Type which is not a
registered media type for the XHTML 1.1 Document Type. The recommended
media type for this document is: application/xhtml+xml

The index file is called index.shtml since it uses some SSI. To tell
this to the server, I include a little .htaccess file in the directory
containing the following line:

DirectoryIndex index.shtml

I tried to fix the warning by adding the following:

# AddType application/xhtml+xml shtml html

But then the SSI no longer works, and Firefox shows the page with a
white border around <body>. Same thing happens if I call it index.xhtml.

Seems like this is a Firefox bug? What is the proper way to handle this?

Cheers, H.
--
Hendrik Maryns
http://tcl.sfs.uni-tuebingen.de/~hendrik/
==================
http://aouw.org
Ask smart questions, get good answers:
http://www.catb.org/~esr/faqs/smart-questions.html
Jun 27 '08 #1
Share this Question
Share on Google+
3 Replies


P: n/a
On Fri, 6 Jun 2008, Hendrik Maryns wrote:
First of all, this is probably a little OT here,
please point me to a better place if you deem that appropriate.
<news:comp.infosystems.www.servers.unix>
The document is being served with the text/html Mime Type which is not a
registered media type for the XHTML 1.1 Document Type. The recommended media
type for this document is: application/xhtml+xml
Short answer:

Do not use application/xhtml+xml and XHTML 1.1 on the web if you want
to be read by everyone. You could do this for some testing etc.

For publication on the web, use text/html with HTML 4 Strict or
XHTML 1.0 Strict.

--
In memoriam Alan J. Flavell
http://groups.google.com/groups/sear...Alan.J.Flavell
Jun 27 '08 #2

P: n/a
Hendrik Maryns wrote:
The document is being served with the text/html Mime Type which is not
a registered media type for the XHTML 1.1 Document Type.
See this:
http://tekrider.net/html/doctype.php
The recommended media type for this document is: application/xhtml+xml
...and Internet Explorer users won't be able to use your page.

--
-bts
-Friends don't let friends drive Windows
Jun 27 '08 #3

P: n/a
Beauregard T. Shagnasty schreef:
Hendrik Maryns wrote:
>The document is being served with the text/html Mime Type which is not
a registered media type for the XHTML 1.1 Document Type.

See this:
http://tekrider.net/html/doctype.php
>The recommended media type for this document is: application/xhtml+xml

..and Internet Explorer users won't be able to use your page.
Thanks both. That’s what I suspected. I’ll live with the warning until
the world gets better (i.e. Firefox displays it properly and IE displays
it at all).

Cheers, H.
--
Hendrik Maryns
http://tcl.sfs.uni-tuebingen.de/~hendrik/
==================
http://aouw.org
Ask smart questions, get good answers:
http://www.catb.org/~esr/faqs/smart-questions.html
Jun 27 '08 #4

This discussion thread is closed

Replies have been disabled for this discussion.