You learn something new every day: 404.html file size issues?

Ξ February 21st, 2008 | → | ∇ HTML, Microsoft |

I found this in a friend’s 404.html file:

< !--
- Unfortunately, Microsoft has added a clever new
- “feature” to Internet Explorer. If the text of
- an error’s message is “too small”, specifically
- less than 512 bytes, Internet Explorer returns
- its own error message. You can turn that off,
- but it’s pretty tricky to find switch called
- “smart error messages”. That means, of course,
- that short error messages are censored by default.
- IIS always returns error messages that are long
- enough to make Internet Explorer happy. The
- workaround is pretty simple: pad the error
- message with a big comment like this to push it
- over the five hundred and twelve bytes minimum.
- Of course, that’s exactly what you’re reading
- right now.
–>

Does anyone know if that is still the case? I haven’t come across this before, but it is sure worth knowing about even if it is ie6 specific…

 

2 Responses to ' You learn something new every day: 404.html file size issues? '

Subscribe to comments with RSS or TrackBack to ' You learn something new every day: 404.html file size issues? '.


  1. on February 21st, 2008 at 1:50 pm

    AFAIK, that is still the case. “Friendly” error messages might have been a nice idea if they hadn’t been on by default (maybe ask to enable at install time), or if they presented themselves as some sort of clickable status icon in the UI.

  2. Mark Jaquith said,

    on February 21st, 2008 at 11:59 pm

    Looks like it is valid for IE 5 and IE 6, at least.

    I’ve seen that particular “padding” comment before… must ship with something popular. We had to do a similar thing to WordPress XML exports because Firefox and Safari both got “cute” with text/xml and treated it as a feed (ignoring the Content-Disposition header).

Leave a reply