<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>睡到25点 &#187; HTTP 404</title>
	<atom:link href="http://www.voidman.com/tag/http-404/feed" rel="self" type="application/rss+xml" />
	<link>http://www.voidman.com</link>
	<description>个人博客，记录与分享。</description>
	<lastBuildDate>Thu, 12 Jan 2012 14:00:32 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>IE 不正常显示 WordPress 404 错误页面</title>
		<link>http://www.voidman.com/2008/03/wordpress-404-page-not-work-well-in-ie.html</link>
		<comments>http://www.voidman.com/2008/03/wordpress-404-page-not-work-well-in-ie.html#comments</comments>
		<pubDate>Sun, 09 Mar 2008 12:55:27 +0000</pubDate>
		<dc:creator>David</dc:creator>
				<category><![CDATA[Blog Related]]></category>
		<category><![CDATA[HTTP 404]]></category>
		<category><![CDATA[IE]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.voidman.com/2008/03/wordpress-404-page-not-work-well-in-ie.html</guid>
		<description><![CDATA[突然发现在 IE 下面 WordPress 的 404 页面不起作用了，而 FireFox、Opera 正常。 按照微软的说法：当网站的 404 错误页面小于 512 字节时，IE 不会显示网站定义的错误页面，取而代之显示 IE 缺省的友好 HTTP 错误信息。很显然，我的 404 页面不可能小于 512 字节。既然 FireFox、Opera 都正常，那问题肯定出在 IE 身上了，我判断是 IE 解析服务器返回的 404 页面时出了问题，导致 IE 认为服务器返回的页面大小不足 512 字节，因而显示了自身的错误页面。 为了防止 UTF-8 字符集网页在 IE 上会出现显示空白问题，通常我们都会把设定字符集的 &#8230; <a href="http://www.voidman.com/2008/03/wordpress-404-page-not-work-well-in-ie.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>突然发现在 IE 下面 WordPress 的 404 页面不起作用了，而 FireFox、Opera 正常。</p>
<p>按照<a href="http://support.microsoft.com/default.aspx?scid=kb;en-us;Q294807">微软的说法</a>：当网站的 404 错误页面小于 512 字节时，IE 不会显示网站定义的错误页面，取而代之显示 IE 缺省的友好 HTTP 错误信息。很显然，我的 404 页面不可能小于 512 字节。既然 FireFox、Opera 都正常，那问题肯定出在 IE 身上了，我判断是 IE 解析服务器返回的 404 页面时出了问题，导致 IE 认为服务器返回的页面大小不足 512 字节，因而显示了自身的错误页面。</p>
<p>为了防止 UTF-8 字符集网页在 IE 上会出现显示空白问题，通常我们都会把设定字符集的 meta 标签置于 title 标签之上，所以我修改了 K2 主题，没想到反而出了问题。当我把 meta 重新置于 title 之下时，IE 又可以显示 WordPress 的 404 页面了。查看 404 页面源代码发现头部多出一个空行 （K2 模板有些书写不“规范”）来，去掉空行，404 页面又不显示了。后来又发现将 meta 重新置于 title 之上，404 页面又显示正常了。</p>
<p>让朋友测试，朋友表示他那里 IE 正常显示了 WordPress 的 404 页面，我更晕了。更有意思的是本机测试一切正常。至于到底是什么原因，暂时也没搞清楚。</p>
<p>反正我是彻彻底底被 IE 玩弄了一番。</p>
<p><strong>UPDATE</strong> at 2008.3.14<br />
发现在 WordPress 后台打开 gzip 压缩选项，404 页面居然在 IE 下显示正常了。</p>
<h4>Related Posts</h4><ul class="related_post"><li><a href="http://www.voidman.com/2009/05/using-wordpress-plugin-api-hack-discuz.html" title="WordPress 的 Hook 机制在 Discuz 二次开发中的应用">WordPress 的 Hook 机制在 Discuz 二次开发中的应用</a></li><li><a href="http://www.voidman.com/2009/04/at-reply-mail-notification-1-release.html" title="At Reply Mail Notification 1.0 Release">At Reply Mail Notification 1.0 Release</a></li><li><a href="http://www.voidman.com/2009/03/lbs-to-wordpress.html" title="LBS 转 WordPress 不完全记录">LBS 转 WordPress 不完全记录</a></li><li><a href="http://www.voidman.com/2009/01/wordpress-is-using-a-bad-way-to-detect-duplicate-comment.html" title="Wordpress 糟糕的重复评论检测方式">Wordpress 糟糕的重复评论检测方式</a></li><li><a href="http://www.voidman.com/2009/01/at-reply-mail-notification-test.html" title="At Reply Mail Notification 测试贴">At Reply Mail Notification 测试贴</a></li><li><a href="http://www.voidman.com/2008/11/automatically-delete-post-revisions.html" title="让 Wordpress 自动删除 Post Revisions">让 Wordpress 自动删除 Post Revisions</a></li><li><a href="http://www.voidman.com/2008/11/google-xml-sitemaps-ignore-the-specified-categories.html" title="让 Google Sitemaps Generator 可以忽略指定的日志分类">让 Google Sitemaps Generator 可以忽略指定的日志分类</a></li><li><a href="http://www.voidman.com/2008/11/the-better-solution-for-static-paged-post.html" title="Wordpress 分页文章静态化的更优解决方案">Wordpress 分页文章静态化的更优解决方案</a></li><li><a href="http://www.voidman.com/2008/07/upgraded-to-wordpress-v26.html" title="升级到 WordPress 2.6">升级到 WordPress 2.6</a></li><li><a href="http://www.voidman.com/2008/03/upgraded-to-wordpress-25-rc1.html" title="升级到 WordPress 2.5 RC1">升级到 WordPress 2.5 RC1</a></li></ul><hr /><a href="http://www.voidman.com">Voidman.com</a> | Link: <a href="http://www.voidman.com/2008/03/wordpress-404-page-not-work-well-in-ie.html">http://www.voidman.com/2008/03/wordpress-404-page-not-work-well-in-ie.html</a><br /><img alt="linezing" width="1" height="1" src="http://img.tongji.linezing.com/288120/tongji.gif" />]]></content:encoded>
			<wfw:commentRss>http://www.voidman.com/2008/03/wordpress-404-page-not-work-well-in-ie.html/feed</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
	</channel>
</rss>

