wordpress在登录后台出现“Warning: Cannot modify header information - headers already sent by”的解决办法

wordpress在登录后台出现“Warning: Cannot modify header information - headers already sent by”的解决方法

当你在使用wordpress或者其他用php写的网页时,如果出现Warning: Cannot modify header information - headers already sent by……,那么下面的方法可以解决:

找到sent by后面的.php文件,用notepad++打开,选择格式->转为UTF-8无BOM编码格式!

因为如果使用utf-8编码,一定要去掉UTF-8中的BOM,这由于utf-8编码文件含有的bom的原因,而php4,5都是不支持bom的。