Three little characters  designed to make your life hell
By Martyn in Programming | 5 comments
On more than one occasion these characters  have turned up just when everything else seems fine. Known as a “BOM” or Byte Order Mark they can be extremely annoying.
What is  ???
 is often seen at the top left corner of a web page. When you open the source file and compare that to the output source you will not find , so what causes  to appear in your file?
The reason is your editor has saved the file as UTF-8. With the ever increasing complexity of character encoding some editors ignore your settings and update your configuration to use UTF-8. Even if you have been using ASCII without any trouble since 1982!
The Fix
Change the character encoding of your page. With most editors all you need to do is select properties and then choose ASCII then save the file.
Changing the meta tag alone is not enough, with extended attributes on files now no one can be sure where a browser or whatever reader your using will use to determine how to display it.
email this | tag this | digg this | trackback | comment RSS feed
Ho Huynh | Apr 23, 2009 | Reply
Thanks for your information.
Bob | Aug 21, 2009 | Reply
Great tip – that has bugged me for ages!
mansour | Oct 14, 2009 | Reply
Thank you. Your information resolved a problem that was driving me nuts.
Euan Gordon | Dec 21, 2009 | Reply
It’s good to know I’m not the only one with these characters!
OMG | Jan 23, 2010 | Reply
OMG thank you very much.
That works like hell.