« back to discussion

File Encodings

I found this article to be very enlightening.

I admit, I knew probably less than I should have.. basically, if it looks like garbage .. mash the keys, produce different charsets and hope it works on one of them.

Here are my lingering questions, if anyone has any insight:

  1. Should a php/html/what-have-you file charset 100% of the time match the encoding of the file? Somehow I never put 1+1 together that a file can be encoded differently than what the charset is set to in meta info.

  2. In what situation might you use ISO-8859-1 instead of UTF-8?

  3. I understand that encodings were originally meant to be passed in the header, and later allowed to be written in the html/email itself... but if the encoding is already in the file itself, why must it be written in the file?

over 5 years ago, by pineapple

3 Replies


To be honest, knowing what I do in that article makes things so much easier. I suppose I never realized how many encoding problems I run across and they randomly 'fix' by me trying things that I don't really know what I'm doing.

In the last few days I've encountered it at least 5+ times, and now I'm fixing them and I know exactly what I'm doing -- good stuff.

pineapple, over 5 years ago


I'm loving the encoding articles! I have to admit I didn't know anything about them before expect they were weird and confusing.

SkinnyGeek1010, over 5 years ago

Login or to comment.

« back to discussion

Tutorials are any resources you learn from.

Examples: an intro to html5 screencast, a pdf about git, photoshop effects tutorials, meta-programming in ruby, lambda calculus, higher-order fixed-point combinators.

Tools are websites, apps or services used -on- your project (indirectly), to aid the process.

Examples: A color scheme generator, email marketing software, usability heat maps, css3 code generators, a downloadable png compressor.

Assets are downloadable files used -in- your projects, usually as code, textures, or images.

Examples: a jquery sticky menu, photoshop brushes, background textures, mvc frameworks, twitter bootstrap, 960 grid system.