Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Click here to return to the 'Unix command files, UTF-8, and the byte order mark' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Unix command files, UTF-8, and the byte order mark
Authored by: palahala on Apr 06, '09 04:56:12PM
BOM is not needed for UTF-8 files

True, if you know it is UTF-8. If you (or the processor of your file) do not know, and have no other means of specifying the encoding, then the BOM might be useful for UTF-8 as well. But I have not seen such cases yet. For example: the structure of both HTML and XML allow for specifying the encoding in the top of the actual content.

In fact, I guess that if Bash would have supported UTF-8 command files, then the BOM would actually have been needed.

[ Reply to This | # ]