喜悦国际村 
» 游客:  注册 | 登录 | 搜索 | 统计 | 喜悦证交所 | 帮助

RSS 订阅当前论坛  

上一主题 下一主题
     
标题: [问题] Cannot send session cookie 是什么错误,要怎么解决  
 
wildhoney053
新手上路
Rank: 1



UID 119985
精华 0
积分 7
帖子 3
金钱 7 喜悦币
威望 0
人脉 0
阅读权限 10
注册 2008-4-24
状态 离线
Cannot send session cookie 是什么错误,要怎么解决

页面显示这个错误:     我在本地虚拟机上测试是好的!平台是:windous 2003 server+apache+php+mysql
Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at D:\haolingtong\inc\config.php:1) in D:\haolingtong\inc\config.php on line 2

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at D:\haolingtong\inc\config.php:1) in D:\haolingtong\inc\config.php on line 2


代码如下:
<?php
session_start();                                就是显示这个是第二行错误
$webname = "好灵通后台";
$webtitle= "好灵通分类信息网";
$db_host = "localhost";
$db_user = "haolingtong";
$db_password = "haolingtong2008";
$db_name = "haolingtong";
if ( !@( $conn = @mysql_connect( @$db_host, @$db_user, @$db_password ) ) )
{
    exit( "错误原因 : 数据库连接不上或数据库帐号密码不正确。" );
}
mysql_query( "set names utf-8" );
if ( !mysql_select_db( $db_name ) )
{
    exit( "错误原因 : 数据库不存在".$db_name );
}
?>
2008-4-25 10:22 AM#1
查看资料  发短消息  顶部
     


  可打印版本 | 推荐给朋友 | 订阅主题 | 收藏主题 | 开通个人空间  


 


Powered by Discuz! 6.1.0  © 2001-2010 Comsenz Inc.
Processed in 0.022425 second(s), 6 queries

(冀ICP备05009913号) 管理员:sadly 邮箱/MSN: sadly@phpx.com QQ:824008(长隐) 清除 Cookies - - Archiver - WAP