中午变化了一下博客主题,结果就登不上了。提示错误如下:

Warning: Cannot modify header information - headers already sent by (output started at /home/to/public_html/en/wp-content/themes/nordby/functions.php:78) in /home/to/public_html/en/wp-login.php on line 418

Warning: Cannot modify header information - headers already sent by (output started at /home/to/public_html/en/wp-content/themes/nordby/functions.php:78) in /home/to/public_html/en/wp-login.php on line 431

问题出在/home/to/public_html/en/wp-content/themes/nordby/functions.php这个文件上。这是错误的文件截图,可以看到结尾有空白行:

err

修改成这样就可以了:

right

参考资料:
Cannot modify header information – headers already sent by …