More information about the Underscore mailing list

[_] Error : PHP Warning: Cannot modify header information - headers already sent

Mike Karthauser mikek at brightstorm.co.uk
Mon Mar 19 07:41:38 GMT 2018

Hi Martin
This error is usually caused by white space before your headers are sent. Look for a new line outside of php tags - should be spottable if you diff your recent commits in git.

Best Regards
Mike
--
Mike Karthauser
Managing Director - Brightstorm Ltd
Email: mikek at brightstorm.co.uk
Web: http://www.brightstorm.co.uk
Tel: 07939 252144 (mobile)
Address: 1 Brewery Court, North Street, Bristol, BS3 1JS

On 19 Mar 2018, 00:04 +0000, Martin Moore <martinm at it-helps.co.uk>, wrote:
> I'm getting a "PHP Warning: Cannot modify header information - headers already sent by (output started at /var/www/codeclink/login/index.php:2) in /var/www/codeclink/login/index.php on line 158"
>
> My understanding is that line 2 is causing problems.
>
>
>
>
> This is line 158 : header('location:home.php');
>
> I've removed some things but can't work out what's wrong. Even done all the stuff Google suggests lol.
>
> Top of the file:
>
> <?php session_start(); ?> // THIS IS LINE 1
> <html
>   <head
>     <!-- <meta charset="utf-8"> --
>     <!-- <meta name="viewport" content="width=device-width, initial-scale=1"> --
>
> <!-- Latest compiled and minified CSS --
> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"
>
> <!-- jQuery library --
> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script
>
> <!-- Latest compiled JavaScript --
> <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script
>
> <!-- <link rel="stylesheet" type="text/css" href="style.css"> --
>
> </head
>
>
>
> --
> underscore_ list info/archive -> http://www.under-score.org.uk/mailman/listinfo/underscore