The following error occurred at the time of Setcookie.
Cannot modify header information-headers already sent by ....
This error is very common, and if you output any text before Setcookie, you will have the error message. Because the page header require a number of files, a row of troubleshooting is very troublesome, so I add at the top of the page:
PLAIN TEXT
PHP:
ob_start();
Add code before Setcookie:
PLAIN TEXT
PHP:
ob_get_clean();
This is to get the content of the page output before Setcookie. After the page runs, the display outputs an empty string, which means that Setcookie has no output before.
Then with vim opened the source file, found vim has open bomb option, suspect therefore to code added a hidden string, closed:
Set Nobomb
Solve the problem.
What does the BOM mean?
The BOM is the abbreviation for "Byte Order Mark", which is used to mark the encoding of the file. Not all text-editing tools recognize BOM marks