function.mysql query_PHP MYSQL数据库连接问题求大神指点迷津,新手入门。 Warning: mysql_query() [function.mysql-query]...

这是PHP代码。。省略一部分***下面是出错的几句$query="select*fromals_signupwhereUserName='{$_SESSION['UserName']}'andPassword='{$_SESSION['Password']}'";$result=mysql_query...

这是PHP代码

。。省略一部分

***下面是出错的几句

$query="select * from als_signup where UserName='{$_SESSION['UserName']}' and Password='{$_SESSION['Password']}'";

$result=mysql_query($query);

$row=mysql_fetch_array($result);

if ($row)

{

//如果session会话变量用户名与密码匹配,则自动登录,直接跳转到管理页面

header("refresh:1;url=http://localhost/members/manage.php");

exit;

}

这是运行的警告!!

Warning: mysql_query() [function.mysql-query]: Access denied for user

'ODBC'@'localhost' (using password: NO) in D:\wamp\www\phptest\config.php

on line 9

Warning: mysql_query() [function.mysql-query]: A link to the server

could not be established in D:\wamp\www\phptest\config.php on line

9

Warning: mysql_query() [function.mysql-query]: Access denied for user

'ODBC'@'localhost' (using password: NO) in D:\wamp\www\phptest\config.php

on line 12

Warning: mysql_query() [function.mysql-query]: A link to the server

could not be established in D:\wamp\www\phptest\config.php on line

12

Error while creating database (Error1045:"Access denied for user

'ODBC'@'localhost' (using password: NO)")

Warning: session_start()

[function.session-start]: Cannot send

session cache limiter - headers already sent (output started at

D:\wamp\www\phptest\config.php:9) in D:\wamp\www\phptest\login.php on

line 4

Warning: mysql_query() [function.mysql-query]: Access denied for user

'ODBC'@'localhost' (using D:\wamp\www\phptest\login.php on line

6

Warning: mysql_fetch_array(): supplied argument is not a

valid MySQL result resource in D:\wamp\www\phptest\login.php on line

7

展开

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值