h5bp / html5-boilerplate

A professional front-end template for building fast, robust, and adaptable web apps or sites.
https://html5boilerplate.com/
MIT License
56.58k stars 12.26k forks source link

humans.txt must be UFT-8 #840

Closed baamenabar closed 13 years ago

baamenabar commented 13 years ago

There is little that can go wrong with a text file, but it has. The humanstxt.org spec specifies the file must be UTF-8, this one is ANSI.

mathiasbynens commented 13 years ago

humans.txt seems to be encoded as UTF-8. How did you determine it’s ANSI?

necolas commented 13 years ago

Looks utf-8 to me too

baamenabar commented 13 years ago

Downloaded the boilerplate (ziped), then modified the humans.txt including my name (which contains non-ANSI characters) and uploaded it, then opened it in the browser, and the characters were garbled. Of course I thought of the charater encoding, (which was odd since all my servers serve utf-8), but the headers sent to the browser are UTF-8, then looked at the file, and it is ANSI, so I changed the charset to UTF-8 in Notepad++, uploaded and problem solved. How are you determining it's UTF-8 and not ANSI?

erikdubbelboer commented 13 years ago

As it is now it's actually just ASCII. Since ASCII is a subset of both UTF-8 and ANSI you can't really say it's either of those. Notepad++ must by default save files in ANSI so that's what happened.

paulirish commented 13 years ago

also we have this.

# Use UTF-8 encoding for anything served text/plain or text/html
AddDefaultCharset utf-8

closing..