Page 1 of 1

Frequent bug

Posted: Thu Feb 18, 2010 1:38 am
by mobotech
Once in awhile, I would get this message when validating my html doc:
Byte-Order Mark found in UTF-8 File.

The Unicode Byte-Order Mark (BOM) in UTF-8 encoded files is known to cause problems for some text editors and older browsers. You may want to consider avoiding its use until it is better supported.
For some reason, the editor inserts this bit at the top of the page near the doctype: 

I needed to find a text editor that can recognize it, than remove it.

Here another post this the same problem: ... 68872.html

Re: Frequent bug

Posted: Thu Feb 18, 2010 8:03 am
by Albert Wiersch
It's unlikely to be a "real-world" issue nowadays, so personally I wouldn't worry about it.

But if you want, you can still remove it, but it might come back depending on what editor you use and how it's programmed to deal with UTF-8 and the BOM (byte order mark).

In some editors, you may be able to remove it simply by saving the file as UTF-8 without the BOM. For example, in CSE HTML Validator you can do this with File->Save with Encoding and choose "Unicode (UTF-8)" with the "Use encoding signature" option unchecked.

Re: Frequent bug

Posted: Thu Feb 18, 2010 2:13 pm
by MikeGale
For some time I've used utf-8 competence to eliminate editors from my workflow.

That looks like the best approach to me. I don't want to be held back by old technology.

For a long time this was hard to do. There were not a lot of "utf-8 competent" editors around. (In fact there was one where a company takeover gave incompetent programmers access to the product and they partly broke a working utf-8 system!)

Now I find it easy. There are a lot of editors that just do it.

You might not have control over your editors. If that's so you'll have a different set of problems.

Re: Frequent bug

Posted: Sun Feb 21, 2010 4:08 am
by TopStyle Support
In TopStyle 4, you have full control over the UTF-8 BOM here: Options (F8) > Editor > Encoding.