Re: session_start() error



On Sat, 30 Apr 2005 09:01:10 GMT, nrhodes@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx
(y_oda2002) wrote:

>I keep getting an error that says this:
>
>Warning: session_start(): Cannot send session cache limiter - headers
>already sent (output started at c:\program files\easyphp1-8\www\the
>site\adminlogin.php:3)

OK, what's in adminlog.php line 3?

>in c:\program files\easyphp1-8\www\thesite\access.inc.php on line 5
>
>Does anyone know what it means?

It means you're trying to start a session, so PHP is trying to send a cookie
and a cache limiter header, but you've already output some content - HTTP
headers can only be sent before any other content.

>I am trying to create a account login
>and that warning comes up... Nothing bad happens. If anything does
>anyone know how to suppress php from showing the warning?

Don't suppress this - it's actually a bit more serious than just a warning as
it'll be screwing up your sessions.

>though I'd rather figure out how to fix it

Yep, much better.

--
Andy Hassall / <andy@xxxxxxxxxxx> / <http://www.andyh.co.uk>
<http://www.andyhsoftware.co.uk/space> Space: disk usage analysis tool
.



Relevant Pages

  • Problem with session_start
    ... I get a warning and cannot start a session. ... the php script before any HTML tags or output to the browser. ... Cannot send session cache limiter - headers already sent (output ...
    (comp.lang.php)
  • Re: Vesoft Logoff question
    ... to be counted against the session. ... I put the warning message and time into the logoff.data file. ... * To join/leave the list, search archives, change list settings, * ...
    (comp.sys.hp.mpe)
  • SESSION error -> Your script possibly relies on a session side-effect which existed until PH
    ... Warning: Unknown(): Your script possibly relies on a session side-effect which existed until PHP 4.2.3. ... Please be advised that the session extension does not consider global variables as a source of data, ...
    (comp.lang.php)
  • "register_globals off" and "session side-effect"
    ... Warning: Unknown(): Your script possibly relies on a session side- ... I should replace all global variables which I care ...
    (comp.lang.php)
  • Please help. That darn header command
    ... Cannot send session cookie - headers already sent by (output ... Warning: Cannot send session cache limiter - headers already sent (output ...
    (comp.lang.php)