Cannot send session cookie - headers already sent
Moderator: General Support Moderators
Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
-
- Joomla! Intern
- Posts: 81
- Joined: Thu Oct 23, 2008 10:59 am
Re: Cannot send session cookie - headers already sent
Hello Joomla gurus - I'm needing some help.
Fresh install of 1.5.22. All works good, until I try to run a phpbb3 module of daily digest.
What the heck does this mean? My config is great, it happens on all browsers, and seems only related to joomla.
Lines 423 of session.php are -
function _start()
{
// start session if not startet
if( $this->_state == 'restart' ) {
session_id( $this->_createId() );
}
Line 423 --- session_cache_limiter('none');
session_start();
// Send modified header for IE 6.0 Security Policy
Line 426 --- header('P3P: CP="NOI ADM DEV PSAi COM NAV OUR OTRo STP IND DEM"');
return true;
It returns the error:
Starting mail_digests.php
[phpBB Debug] PHP Notice: in file /home1/lxxxx/public_html/peelparamedics/libraries/joomla/session/session.php on line 423: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /mail_digests.php:1118)
[phpBB Debug] PHP Notice: in file /home1/xxxx/public_html/peelparamedics/libraries/joomla/session/session.php on line 423: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /mail_digests.php:1118)
[phpBB Debug] PHP Notice: in file /home1/xxxx/public_html/peelparamedics/libraries/joomla/session/session.php on line 426: Cannot modify header information - headers already sent by (output started at /mail_digests.php:1118)
Ending mail_digests.php
Joomla gurus please help.
Thanks
Tim
Fresh install of 1.5.22. All works good, until I try to run a phpbb3 module of daily digest.
What the heck does this mean? My config is great, it happens on all browsers, and seems only related to joomla.
Lines 423 of session.php are -
function _start()
{
// start session if not startet
if( $this->_state == 'restart' ) {
session_id( $this->_createId() );
}
Line 423 --- session_cache_limiter('none');
session_start();
// Send modified header for IE 6.0 Security Policy
Line 426 --- header('P3P: CP="NOI ADM DEV PSAi COM NAV OUR OTRo STP IND DEM"');
return true;
It returns the error:
Starting mail_digests.php
[phpBB Debug] PHP Notice: in file /home1/lxxxx/public_html/peelparamedics/libraries/joomla/session/session.php on line 423: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /mail_digests.php:1118)
[phpBB Debug] PHP Notice: in file /home1/xxxx/public_html/peelparamedics/libraries/joomla/session/session.php on line 423: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /mail_digests.php:1118)
[phpBB Debug] PHP Notice: in file /home1/xxxx/public_html/peelparamedics/libraries/joomla/session/session.php on line 426: Cannot modify header information - headers already sent by (output started at /mail_digests.php:1118)
Ending mail_digests.php
Joomla gurus please help.
Thanks
Tim
-
- Joomla! Apprentice
- Posts: 5
- Joined: Tue May 10, 2011 1:03 pm
Re: Cannot send session cookie - headers already sent
Ok you can simply laugh at how I solved mine:
I was working on some other stupid error, when I got the new error of: "Cannot send session cache blah blah blah" (the error this forum is about!)
Anyway, I followed your suggestions although I hadn't done/edit any of the things you mentioned.nothing worked and it was no surprise since i was clean on those doings.
At last, as a pity act, I opened my main configuration.php file, I changed encoding to ANSI; there were no blanks,no disorders. However, i pressed "space", then "enter" randomly between some lines! (FYI,remember where you do it!!) I changed everything back to normal at the end and saved my file. and IT'S OK NOW!!
I guess it's a million dollar question of : what the heck was that!!
anyway, hope this helps and hope we won't face any metaphysical errors in Joomla again!!!
I was working on some other stupid error, when I got the new error of: "Cannot send session cache blah blah blah" (the error this forum is about!)
Anyway, I followed your suggestions although I hadn't done/edit any of the things you mentioned.nothing worked and it was no surprise since i was clean on those doings.
At last, as a pity act, I opened my main configuration.php file, I changed encoding to ANSI; there were no blanks,no disorders. However, i pressed "space", then "enter" randomly between some lines! (FYI,remember where you do it!!) I changed everything back to normal at the end and saved my file. and IT'S OK NOW!!
I guess it's a million dollar question of : what the heck was that!!
anyway, hope this helps and hope we won't face any metaphysical errors in Joomla again!!!
-
- Joomla! Fledgling
- Posts: 2
- Joined: Sat May 14, 2011 6:23 am
- Contact:
Re: Cannot send session cookie - headers already sent
The file format of the configuration file had resolved my issue as well. Thanks all
http://www.hediyelikesyalar.net Hediye Merkezi
-
- Joomla! Fledgling
- Posts: 1
- Joined: Mon Mar 14, 2011 7:02 pm
Re: Cannot send session cookie - headers already sent
Hello I'm having this issue, I'm migrating my website from one hosting a new one with a different vendor, and I'm getting errors with session.
This is the first time I get this error..
Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /homepages/28/d283790822/htdocs/configuration.php:1) in /homepages/28/d283790822/htdocs/libraries/joomla/session/session.php on line 423
Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /homepages/28/d283790822/htdocs/configuration.php:1) in /homepages/28/d283790822/htdocs/libraries/joomla/session/session.php on line 423
Warning: Cannot modify header information - headers already sent by (output started at /homepages/28/d283790822/htdocs/configuration.php:1) in /homepages/28/d283790822/htdocs/libraries/joomla/session/session.php on line 426
If some one could help me,
Thanks in advance,
Sunny
This is the first time I get this error..
Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /homepages/28/d283790822/htdocs/configuration.php:1) in /homepages/28/d283790822/htdocs/libraries/joomla/session/session.php on line 423
Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /homepages/28/d283790822/htdocs/configuration.php:1) in /homepages/28/d283790822/htdocs/libraries/joomla/session/session.php on line 423
Warning: Cannot modify header information - headers already sent by (output started at /homepages/28/d283790822/htdocs/configuration.php:1) in /homepages/28/d283790822/htdocs/libraries/joomla/session/session.php on line 426
If some one could help me,
Thanks in advance,
Sunny
-
- Joomla! Enthusiast
- Posts: 122
- Joined: Thu Jul 31, 2008 9:23 pm
- Location: United States
[SOLVED] Cannot send session cookie - headers already sent
That is exactly the issue: using Note or WordPad to edit. The best way is to use a professional tool like DreamWeaver.
This issue happened to me because I had to work at my client's computer and all they had was NotePad.
This issue happened to me because I had to work at my client's computer and all they had was NotePad.
-
- Joomla! Apprentice
- Posts: 10
- Joined: Mon Dec 29, 2008 9:43 am
Re: Cannot send session cookie - headers already sent
Hello,
same problem, same solution (i.e. ANSI saving by Notepad) BUT...
I must add that in my very particular case, maybe useful for somebody else, I got file php.ini renamed with a different extension and this prevented the system to work without getting the "session cookie" error message.
This was due to a temporary suspension of the site by the provider who did not rename the php.ini file once the site was reactivated.
Renaming the file as php.ini in conjunction with the proper ANSI saving of file configuration.php fixed the issue.
Hope this helps,
Marco
same problem, same solution (i.e. ANSI saving by Notepad) BUT...
I must add that in my very particular case, maybe useful for somebody else, I got file php.ini renamed with a different extension and this prevented the system to work without getting the "session cookie" error message.
This was due to a temporary suspension of the site by the provider who did not rename the php.ini file once the site was reactivated.
Renaming the file as php.ini in conjunction with the proper ANSI saving of file configuration.php fixed the issue.
Hope this helps,
Marco
-
- Joomla! Fledgling
- Posts: 1
- Joined: Wed Apr 03, 2013 5:58 am
Re: Cannot send session cookie - headers already sent
Problem:
I migrated my 1.5.18 site to 1.5.26 --> everything OK
I upgraded some plug ins --> Everything OK
Using Filezilla, I edited config.php file to change the db password
I switched my default PHP version to latest (1&1 host)
After this, I Couldnt login to administration backend with any user. No error, just back to the login form.
I went back to earlier PHP version, then "headers sent" error appear
After reading this post, I realized that Filezilla used Notepad as default to edit configuration.php file.
This is what i did:
Downloaded configuration.php file
Open the file with Notepad++
Convert to ANSI
Insert one line in the file
Save the file
uploaded file
And that's it!!!! I could login again.
Thank you for the hint!!!
I migrated my 1.5.18 site to 1.5.26 --> everything OK
I upgraded some plug ins --> Everything OK
Using Filezilla, I edited config.php file to change the db password
I switched my default PHP version to latest (1&1 host)
After this, I Couldnt login to administration backend with any user. No error, just back to the login form.
I went back to earlier PHP version, then "headers sent" error appear
After reading this post, I realized that Filezilla used Notepad as default to edit configuration.php file.
This is what i did:
Downloaded configuration.php file
Open the file with Notepad++
Convert to ANSI
Insert one line in the file
Save the file
uploaded file
And that's it!!!! I could login again.
Thank you for the hint!!!
-
- Joomla! Fledgling
- Posts: 1
- Joined: Fri Apr 30, 2010 9:45 am
Re: Cannot send session cookie - headers already sent
Hi,
I solved it the same problem by setting 'error_reporting' in the cofiguration.php on '1' .
succes,
Marc
I solved it the same problem by setting 'error_reporting' in the cofiguration.php on '1' .
succes,
Marc
-
- Joomla! Apprentice
- Posts: 25
- Joined: Sun Jul 24, 2011 9:18 am
Re: Cannot send session cookie - headers already sent
I also face the same problem, when I tried Marc said it works...altijdvliegen wrote:Hi,
I solved it the same problem by setting 'error_reporting' in the cofiguration.php on '1' .
succes,
Marc
var $error_reporting = '-1';
TO
var $error_reporting = '1';
Thanks
-
- Joomla! Fledgling
- Posts: 1
- Joined: Thu Mar 12, 2015 9:15 am
Re: Cannot send session cookie - headers already sent
I have the same problem but I resolve it deleting a black line in index.php
This was the problem
And this was the solution
This was the problem
Code: Select all
<?php
/**
* @package Joomla.Site
*
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
if (version_compare(PHP_VERSION, '5.3.1', '<')) {
die('Your host needs to use PHP 5.3.1 or higher to run this version of Joomla!');
}
Code: Select all
<?php
/**
* @package Joomla.Site
*
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
if (version_compare(PHP_VERSION, '5.3.1', '<')) {
die('Your host needs to use PHP 5.3.1 or higher to run this version of Joomla!');
}