Welcome Guest, Not a member yet? Register   Sign In
Session problem
#1

[eluser]new developer[/eluser]
I simplfied my code as follows
Code:
<?php

class Welcome extends Controller {

    function Welcome()
    {
        parent::Controller();    
    }
    

    function index(){
    }
}

?>

It still has problem. The error is
Code:
A PHP Error was encountered

Severity: Warning

Message: Cannot modify header information - headers already sent by (output started at C:\xampp\htdocs\CMS\system\application\controllers\welcome.php:22)

Filename: libraries/Session.php

Line Number: 662

IS there a way around this problem??
#2

[eluser]GSV Sleeper Service[/eluser]
this is quite often due to extra whitespace after the closing php tag.
try removing "?>" from the end of your Welcome controller.
#3

[eluser]new developer[/eluser]
thanx buddy..i was removing extra white spaces from front <?php ..i had a space at the front...but your solution did work..i completely removed ?> from welcome controller..
#4

[eluser]bastones[/eluser]
Remember when you get that error it means there was output before you set the session or similar, and if you're setting sessions, it needs to be right at the top as possible (generally before any echo, HTML and what not).




Theme © iAndrew 2016 - Forum software by © MyBB