求助,php+mysql新手问题

zhangwh6882 2004-07-03 11:11:16
自己的机器上,前几天安装mysql后,安装了vbb3.01论坛,没有更改root密码。昨天晚上启动后php无法访问数据库。
phpmyadmin显示


代码:--------------------------------------------------------------------------------
Welcome to phpMyAdmin 2.5.7


phpMyAdmin tried to connect to the MySQL server, and the server rejected the connection. You should check the host, username and password in config.inc.php and make sure that they correspond to the information given by the administrator of the MySQL server.

Error

MySQL said:


#2004 - Can't create TCP/IP socket (10106)

[Documentation]

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



config.inc.php文件中用户名及密码设置为默认


代码:--------------------------------------------------------------------------------
$cfg['Servers'][$i]['user'] = 'root'; // MySQL user
$cfg['Servers'][$i]['password'] = '';
--------------------------------------------------------------------------------


但是执行

C:\>C:\mysql\bin\mysqlshow
会显示数据库结构
+-----------+
| Databases |
+-----------+
| cneportal |
| mysql |
| test |
+-----------+

而且EMS MySQL Manager 2中也可以访问数据库。
请问该怎样解决
...全文
109 4 打赏 收藏 转发到动态 举报
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
52juanjuan 2004-07-04
  • 打赏
  • 举报
回复
应该是phpmyadmin中主机地址没有设置对的原故
笨魚 2004-07-04
  • 打赏
  • 举报
回复
phpmyadmin 没设置对,你再看看!

把IP地址 改成 127.0.0.1
ccterran 2004-07-03
  • 打赏
  • 举报
回复
主机地址设对了吗
sfply 2004-07-03
  • 打赏
  • 举报
回复
VBB会否修改了你的ROOT密码

21,887

社区成员

发帖
与我相关
我的任务
社区描述
从PHP安装配置,PHP入门,PHP基础到PHP应用
社区管理员
  • 基础编程社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧