My PHP script have all echoes commented. But if I'd run it from the command line I will receive 'О╩©' (without quotes) in the very beginning of the script execution. I'm concerning as the script is intended to be run from crontab and each execution generates new email with empty message body (only two LFs after the message header). How can I track the source of this unnecessary output? (Sorry - the script is too large to be posted here)
Asked
Active
Viewed 112 times
2
-
3Please check your encoding. – Jenson M John Jan 11 '14 at 09:18
-
1Encoding was UTF-8. I tried to switch to UTF8 wo BOM. Let's see what I will get... – Roman Matveev Jan 11 '14 at 09:21
-
1See the answer to http://stackoverflow.com/questions/8028957/headers-already-sent-by-php. Especially the part about UTF-8 BOM. – user555 Jan 11 '14 at 09:21
1 Answers
4
Seems like your file has Byte Order Mark [BOM]
signature at the start, save your file encoding as UTF8 without BOM
.
In Notepad++ Try : Encode -> Encode in UTF-8 without BOM

Jenson M John
- 5,499
- 5
- 30
- 46
-
1
-
1@RomanMatveev No problem..:) You can mark the answer as accepted later that'll help others too..:) – Jenson M John Jan 11 '14 at 09:33