session_start() [function.session-start]: Cannot send session cache limiter
<p>I'm getting the following warnings when trying to initiate a session:</p>

<pre><code>Warning: session_start() [function.session-start]: 
Cannot send session cache limiter - headers already sent 
(output started at /www/zxq.net/l/i/b/librarymanagement/htdocs/public/admin/index.php:2) 
in /www/zxq.net/l/i/b/librarymanagement/htdocs/includes/session.php on line 9
</code></pre>

<p>I've made sure all white space is clear, <code>session_start()</code> should be the first thing being called. I don't think anything else is being sent before <code>session_start()</code> is called.</p>

<p>Here is my code:</p>

<pre><code>class Session {
    private $logged_in=false;
    public $user_id;
    public $message;
    function __construct() {
        session_start();
        $this-&gt;check_message();
        $this-&gt;check_login();
        if($this-&gt;logged_in) {
        } else {
        }
    }

    public function is_logged_in() {
        return $this-&gt;logged_in;
    }
    public function login($user) {
        if($user) {
            $this-&gt;user_id = $_SESSION['user_id'] = $user;
            $this-&gt;logged_in = true;
        }
    }  
    public function logout() {
        unset($_SESSION['user_id']);
        unset($this-&gt;user_id);
        $this-&gt;logged_in = false;
    }
    public function message($msg="") {
        if(!empty($msg)) {
            $_SESSION['message'] = $msg;
        } else {
            return $this-&gt;message;
        }
    }
    private function check_login() {
        if(isset($_SESSION['user_id'])) {
            $this-&gt;user_id = $_SESSION['user_id'];
            $this-&gt;logged_in = true;
        } else {
            unset($this-&gt;user_id);
            $this-&gt;logged_in = false;
        }
    }  
    private function check_message() {
        if(isset($_SESSION['message'])) {
            $this-&gt;message = $_SESSION['message'];
            unset($_SESSION['message']);
        } else {
            $this-&gt;message = "";
        }
    }

}
</code></pre>

<p>Here is how it is used:</p>

<pre><code>$session = new Session();
$message = $session-&gt;message();
</code></pre>

<p>What could be the problem?</p>
