Cannot send session cookie - headers already sent by
<p>I've a php script the first thing in the code is <code>session_start();</code>, but I keep receiving this error </p>

<p><code>Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /home/****/public_html/admincp/index.php:1) in /home/****/public_html/admincp/index.php on line 1</code></p>

<p>but the script works great in the <code>localhost</code>. </p>

<pre><code>&lt;?php session_start();?&gt;
&lt;?php
require 'global.php';
?&gt;


&lt;?php

//check if the user logged in
if(!isset($_SESSION['user_id']))
page_redirect('login.php'); // go to login.php.
?&gt;
</code></pre>
