Note that there are some explanatory texts on larger screens.

plurals
  1. POPHP Sessions - Warnings
    primarykey
    data
    text
    <p>I asked the question "php warning - headers already sent after server move" yesterday and I have made changes since to try and fix the problem but im still not getting it!</p> <p>I am working on code that has been made by another company! Im not moving the site off their server and putting it on ours but the my problem is that sessions are not working across the pages on the new server! </p> <p>I am getting the warning:</p> <blockquote> <p>Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /home/com10002/public_html/bank/index.php:28) in /home/com10002/public_html/bank/includes/quickform.php on line 3</p> </blockquote> <p>In my index.php</p> <pre><code>include('includes/functions.php'); $activeTab = "navhome"; $sent = false; $title = (isset($_GET['title']))? mysql_real_escape_string($_GET['title']) : 'Home'; $title = str_replace('-',' ', $title); if($title != '') { $sql = "SELECT * FROM contents WHERE name LIKE '%$title%' LIMIT 1"; $result = @mysql_query($sql); $row = mysql_fetch_assoc($result); } //Set page title $pagetitle = (isset($row['name']) &amp;&amp; $title != 'Home')? ucwords($row['name']) : "Bank Charges"; </code></pre> <p>HTML..HEAD..META DATA AND TITLE TAGS..ECT</p> <pre><code>include('includes/header.php'); &lt;div class="textarea"&gt; &lt;?php include('includes/rightcol.php'); ?&gt; &lt;div id="contentvideo" style="display:none;"&gt;&lt;/div&gt; &lt;h1&gt;&lt;?=$row['h1'];?&gt;&lt;/h1&gt; &lt;h2&gt;&lt;?=$row['h2'];?&gt;&lt;/h2&gt; &lt;?=$row['intro'];?&gt; &lt;?php include('includes/quickform.php');?&gt; &lt;?=$row['page_content'];?&gt; &lt;/div&gt; &lt;?php include('includes/subnav.php'); ?&gt; </code></pre> <p>and in quickform.php </p> <pre><code>if($_POST) { session_start(); $error = false; $captcha = false; $sent = false; etc....... </code></pre> <p>This is their code and currently works fine on the their server! </p> <p>1) I have tried moving the <code>session_start()</code> to the top of <code>index.php</code> 2) Putting a session on both pages. 3) Removing white space before the session when it was in the index.php</p> <p>My new version is the site is at <code>www.compensation-claims.org/bank</code></p> <p>Because this is not my code im not sure as to why they put the session in the quickform.php</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload