[SOLVED] Warning: session_start(): Cannot send session cooki
Posted: Fri Jun 24, 2005 4:27 pm
HI,
I have looked at all the forums and i seem to be doing all they ask but i still get the following message
Warning: session_start(): Cannot send session cookie - headers already sent by (output started at c:\inetpub\wwwroot\rivaaz\index.php:1) in c:\inetpub\wwwroot\rivaaz\index.php on line 1
Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at c:\inetpub\wwwroot\rivaaz\index.php:1) in c:\inetpub\wwwroot\rivaaz\index.php on line 1
the follwing is php code which contains all the session stuff. also i have a inlude language file
---------- index.php---------------------------------------------------
-------------include language file lang.php--------------------------------
most of the forums suggest having the start_session at the top . Ive tired changing it around but no luck.
im using php4.3 os win xp with iis 4
i hope some one can guide me where im going wrong
I have looked at all the forums and i seem to be doing all they ask but i still get the following message
Warning: session_start(): Cannot send session cookie - headers already sent by (output started at c:\inetpub\wwwroot\rivaaz\index.php:1) in c:\inetpub\wwwroot\rivaaz\index.php on line 1
Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at c:\inetpub\wwwroot\rivaaz\index.php:1) in c:\inetpub\wwwroot\rivaaz\index.php on line 1
the follwing is php code which contains all the session stuff. also i have a inlude language file
---------- index.php---------------------------------------------------
Code: Select all
<?session_start();
if (!isset($_REQUEST['lang']))
{
$def_lang="en";
session_register("user_lang");
$HTTP_SESSION_VARS['user_lang']=$def_lang;
}
else
{
$HTTP_SESSION_VARS['user_lang']=$_REQUEST['lang'];
}
include("inc/langs/lang.php");
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head>
<title>RIVAAZ</title>Code: Select all
<?
if ($_SESSION['user_lang']=="en")
{
$home="HOME";
$collection="COLLECTION";
$about="ABOUT";
$contact="CONTACT";
}
?>im using php4.3 os win xp with iis 4
i hope some one can guide me where im going wrong