IE中的application / xhtml + xml [英] application/xhtml+xml in IE

查看:259
本文介绍了IE中的application / xhtml + xml的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我今天刚看完这篇文章:

http://webstandards.org/buzz/archive/2005_09.html

我需要一些帮助才能理解这句话:


W3C建议XHTML 1.1应该与

应用程序/ xhtml + xml MIME类型一起提供,这是Internet

资源管理器当前不支持的内容。


我以为是web *服务器*提供某种

MIME类型的文档,而不是web *浏览器*。我不明白为什么重要的是IE

*知道*只要页面有效,就会处理XHTML

正确Content-Type标题,并在浏览器中正确显示。


Gustaf

解决方案

Gustaf写道:

我今天刚读完这篇文章:

http://webstandards.org/buzz/archive/2005_09.html

我需要一些帮助才能理解这句话:

application / xhtml + xml MIME类型一起提供,这是Internet
Explorer当前不支持的东西。

我认为它是web * server *以某种
MIME类型提供文档,而不是web *浏览器*。我不知道为什么IE
*知道*只要页面有效,使用正确的Content-Type标头提供
并正确显示,它是否正在处理XHTML在
浏览器中。




如果文档根本没有显示,这当然很重要;)


IE无法将文件* * *作为application / xhtml + xml识别为可以显示的

文档。如果您尝试加载此类文档,它将弹出另存为...,打开...或

dunno对话框。而且一个XHTML 1.1文件

无效,如果它作为text / html提供 - 唯一的MIME类型IE

理解(用于显示(X)HTML文档)。


以文本/ html的形式提供XHTML 1.0是有效的,并由W3C提倡作为一个临时解决方案,但许多人(包括我)认为这是一个应该避免的丑陋,不必要的黑客攻击。 XHTML 1.0在HTML 4.01上没有附加值

,特别是如果用作text / html。


-

Benjamin Niemann

电子邮件:粉红色at odahoda dot de

WWW: http://www.odahoda.de/


Benjamin Niemann写道:

IE不将文件*作为application / xhtml + xml识别为可以显示的文件。如果你试图加载这样的文件,它会弹出一个''另存为'',''打开...'或
dunno对话框。




这很奇怪。我开始切换到XHTML 1.1,我在Windows XP SP2上的IE6中没有

问题。也许你提到的问题在IE5中发生了

(这已经够糟了)。谁能证实这一点?我看到IE6

不包含application / xhtml + xml在接受中

中的HTTP标头请求,但页面仍然正常呈现。也许它不应该。


对于那些感兴趣的人,我写了一些关于如何编写符合条件的XHTML 1.1

文档(URL是临时的)。请享用。 :-)

http://gusgus.cn /www/xhtml/authoringxhtml11.html


它看起来与IE和Firefox完全相同。在Opera中,< pre>元素是以小字体显示的


Gustaf


Gustaf< gu ** ***@algonet.se>写道:

对于那些感兴趣的人,我写了一些关于如何编写符合条件的XHTML 1.1
文档(URL是临时的)。请享用。 :-)

http://gusgus.cn /www/xhtml/authoringxhtml11.html

IE和Firefox看起来相同。在Opera中,< pre>元素以较小的字体显示。




有趣。我的MSIE副本呈现为


文件下载


您已选择从此位置下载文件。
authoringxhtml11.html


你想用这个文件做什么?

()打开这个文件来自当前位置

(*)将此文件保存到磁盘


[确定] [取消] [更多信息]


如果我选择从当前位置打开此文件,则调用Opera以

显示该文件。

-

Darin McGrew, mc****@stanfordalumni.org http://www.rahul.net/mcgrew/

Web Design Group, da *** @ htmlhelp.com http ://www.HTMLHelp.com/


我曾经处理过生活,但它已经崩溃。


I just read this article from today:

http://webstandards.org/buzz/archive/2005_09.html

I need some help understanding this sentense:

The W3C recommends XHTML 1.1 should be served with the
application/xhtml+xml MIME type, something that Internet
Explorer does not currently support.

I thought it was the web *server* that serves documents in a certain
MIME type, not the web *browser*. I don''t see why it matters whether IE
*knows* it''s dealing with XHTML as long as the page is valid, is served
with a correct Content-Type header, and displayed correctly in the browser.

Gustaf

解决方案

Gustaf wrote:

I just read this article from today:

http://webstandards.org/buzz/archive/2005_09.html

I need some help understanding this sentense:

The W3C recommends XHTML 1.1 should be served with the
application/xhtml+xml MIME type, something that Internet
Explorer does not currently support.

I thought it was the web *server* that serves documents in a certain
MIME type, not the web *browser*. I don''t see why it matters whether IE
*knows* it''s dealing with XHTML as long as the page is valid, is served
with a correct Content-Type header, and displayed correctly in the
browser.



It certainly matters, if the document is not displayed at all ;)

IE does not recognize documents *served* as application/xhtml+xml as a
document it could display. It will popup a ''Save as..'', ''Open with..'' or
dunno dialog, if you try to load such a document. And a XHTML 1.1 document
is not valid, if it is served as text/html - the only MIME type IE
understands (for displaying (X)HTML documents).

Serving XHTML 1.0 as text/html is valid and advocated by the W3C as a
temporary workaround, but many people (including me) think that this is an
ugly, unnecessary hack that should be avoided. XHTML 1.0 has no added value
over HTML 4.01, especially if served as text/html.

--
Benjamin Niemann
Email: pink at odahoda dot de
WWW: http://www.odahoda.de/


Benjamin Niemann wrote:

IE does not recognize documents *served* as application/xhtml+xml as a
document it could display. It will popup a ''Save as..'', ''Open with..'' or
dunno dialog, if you try to load such a document.



That''s strange. I started to make the switch to XHTML 1.1, and I have no
problem in IE6 on Windows XP SP2. Maybe the problem you mention occurs
in IE5 (which is bad enough). Can anyone confirm this? I saw that IE6
doesn''t include "application/xhtml+xml" in the "Accept" HTTP header in
the request, but the page still renders properly. Maybe it shouldn''t.

For those interested, I wrote a bit on how to write conformant XHTML 1.1
documents (the URL is temporary). Enjoy. :-)

http://gusgus.cn/www/xhtml/authoringxhtml11.html

It looks identical IE and Firefox. In Opera, the <pre> elements are
displayed in a smaller font.

Gustaf


Gustaf <gu*****@algonet.se> wrote:

For those interested, I wrote a bit on how to write conformant XHTML 1.1
documents (the URL is temporary). Enjoy. :-)

http://gusgus.cn/www/xhtml/authoringxhtml11.html

It looks identical IE and Firefox. In Opera, the <pre> elements are
displayed in a smaller font.



Interesting. My copy of MSIE renders it as

File Download

You have chosen to download a file from this location.

authoringxhtml11.html from gusgus.cn

What would you like to do with this file?
( ) Open this file from its current location
(*) Save this file to disk

[OK] [Cancel] [More Info]

If I select "Open this file from its current location", then calls Opera to
display the file.
--
Darin McGrew, mc****@stanfordalumni.org, http://www.rahul.net/mcgrew/
Web Design Group, da***@htmlhelp.com, http://www.HTMLHelp.com/

"I used to have a handle on life, but it broke."


这篇关于IE中的application / xhtml + xml的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆