IE6中的空白页面 [英] Blank page in IE6

查看:115
本文介绍了IE6中的空白页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用PHP构建的网站有时会显示一个完全空白的页面。
客户端或服务器上没有错误消息。
同一页面有时可能会显示,但其他页面则不会显示。
所有页面在IE7,Firefox 3,Safari和Opera中都运行良好。
所有页面都是带有此元素的XHTML:

A site I am working on that is built using PHP is sometimes showing a completely blank page. There are no error messages on the client or on the server. The same page may display sometimes but not others. All pages are working fine in IE7, Firefox 3, Safari and Opera. All pages are XHTML with this meta element:

<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=utf-8" />

出现我通过添加此PHP代码修复了问题:

It appears that I have fixed the problem by adding this PHP code:

header('Content-type: text/html; charset=utf-8');

我已经读过这个问题可能是由XHTML,编码,gzip压缩或缓存引起的,但是没有人能够备份这些猜测。

I have read that this problem may be caused by XHTML, encoding, gzip compression, or caching, but nobody has been able to backup these guesses.

由于问题是间歇性的,我不相信我的解决方案实际上已经解决了问题。

As the problem was intermittent I am not confident that my solution has actually solved the problem.

我的问题是,当其他浏览器显示内容时,是否有可重现的方式让IE6显示空白页?
如果是这样,是什么原因导致它解决了什么?

My question is, are there reproducible ways of having IE6 show a blank page when other browsers display content? If so, what causes it and what solves it?

推荐答案

这是来自IE的内容类型问题。
它不知道如何处理application / xhtml + xml。

This is a content-type problem from IE. It does not know how to handle application/xhtml+xml.

虽然你写的是xhtml + xml,但IE只知道text + html。
在所有代理商都知道xhtml + xml

Although you write xhtml+xml, IE only knows text+html. It will be the future before all agents know xhtml+xml

之前将来的未来将内容类型的元标记更改为content =text / html;

change your meta tag with content type to content="text/html;

这篇关于IE6中的空白页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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