Jump to content

Session Error


neugi

Recommended Posts

Hi,

 

i've got a strange problem:

 

i get this errors:

 

Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at e:\Internet\pmtopagents\test.php:1) in e:\Internet\pmtopagents\test.php on line 3

 

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at e:\Internet\pmtopagents\test.php:1) in e:\Internet\pmtopagents\test.php on line 3

 

but in my test.php is nothing else than:

 

<?php
session_start();
?>

 

there is no space in front of <?php

 

where could be the error?

 

best

Link to comment
https://forums.phpfreaks.com/topic/220242-session-error/
Share on other sites

IF (a big if) the error indicated that the session_start() in your posted code was on line 2, I would agree that you don't have any new-line in your file before the <?php tag. However, the error message does not lie.

 

I recommend that you open your file and back-space to the start of the file and the hit the delete key until the < character on the <?php tag is removed to make sure you don't have any characters before the <?php tag.

Link to comment
https://forums.phpfreaks.com/topic/220242-session-error/#findComment-1141369
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.