Warning: session_start() [function.session-start]: Cannot send session cache limiter

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • galacticworld
    New Member
    • Jul 2013
    • 1

    Warning: session_start() [function.session-start]: Cannot send session cache limiter

    The error I'm getting is

    Warning: session_start() [function.sessio n-start]: Cannot send session cache limiter - headers already sent (output started at /home/univix/public_html/index.php:2) in /home/univix/public_html/Global.php on line 25

    ------------------------------------------------

    line 25 is

    Code:
    <?php
    
    
    if(function_exists('get_magic_quotes_gpc') && get_magic_quotes_gpc()) {
        function unMagicQuotify($array) {
            $fixed = array();
            foreach ($array as $key=>$val) {
                if (is_array($val)) {
                    $fixed[stripslashes($key)] = unMagicQuotify($val);
                } else {
                    $fixed[stripslashes($key)] = stripslashes($val);
                }
            }
            return $fixed;
        }
    
        $_GET = unMagicQuotify($_GET);
        $_POST = unMagicQuotify($_POST);
        $_COOKIE = unMagicQuotify($_COOKIE);
        $_REQUEST = unMagicQuotify($_REQUEST);
        $_FILES = unMagicQuotify($_FILES);
    }
    
    session_id();
    session_start(); //thisisline 25
    ob_start();
    
    include "bb.php";
     date_default_timezone_set('America/Chicago');
    $connection = mysql_pconnect("localhost","univix_main","random12") or die ("Error connecting to database.");
    mysql_select_db("univix_main") or die ("Error connecting to database, hang tight, we are working on it.");
    	/*Filter */
    	
    	include "filter.php";
    
    	/*Session */
    	
    	$User = $_SESSION['Username'];
    	$Password = $_SESSION['Password'];
    	$Admin = $_SESSION['Admin'];

    -------------------------------------------
    Please just copy and paste the code how it should be.. I'm new to this coding stuff.

    if you want to see the code, it's at galacticworld.n et/index.php
    Last edited by Rabbit; Jul 30 '13, 12:46 AM. Reason: Please use code tags when posting code or formatted data.
  • Dormilich
    Recognized Expert Expert
    • Aug 2008
    • 8694

    #2
    Cannot send session cache limiter - headers already sent (output started at /home/univix/public_html/index.php:2) in /home/univix/public_html/Global.php on line 25
    session headers (like any other headers) can only be sent if there is no output beforehand.


    if you want to see the code, it's at galacticworld.n et/index.php
    that doesn’t show any PHP code.


    PS. this is one of the top 3 PHP errors.

    Comment

    Working...