By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,302 Members | 1,788 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,302 IT Pros & Developers. It's quick & easy.

Warning: session_start() [function.session-start]: Cannot send session cookie - heade

P: 1
My problem is :

Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /home/xtreme/public_html/forum_tire.php:2) in /home/xtreme/public_html/forum_tire.php on line 26

My Code is :
[php]
// Using PHP5 version
<?php
session_start();

$_SESSION['name'] = $_POST[nm];
$_SESSION['passd'] = $_POST[ps];
?>
[/php]
Plz, help me ASAP..
Mar 21 '08 #1
Share this Question
Share on Google+
2 Replies


P: 82
Hi sanjusb. Delete following line from your script.
[PHP]// Using PHP5 version[/PHP]

P.S. Dont forget to use [code] tags next time you post question.
Mar 21 '08 #2

Markus
Expert 5K+
P: 6,050
My problem is :

Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /home/xtreme/public_html/forum_tire.php:2) in /home/xtreme/public_html/forum_tire.php on line 26

My Code is :

// Using PHP5 version
<?php
session_start();

$_SESSION['name'] = $_POST[nm];
$_SESSION['passd'] = $_POST[ps];
?>

Plz, help me ASAP..
Welcome to TSDN, sanjusb!
Mar 21 '08 #3

Post your reply

Sign in to post your reply or Sign up for a free account.