dongyigua4468 2012-11-12 20:26
浏览 32
已采纳

来自live server的mysql db_connect函数无法正常工作[关闭]

I am tring to connect mySQL db hosted on a live server the line of code to connect db is

mysql_connect("example.com", "webwork_odesk1", "xxxxxxxx" , "webwork1_odesk") or die("Couldn't make connection.");

The username and password are correct but the error displaying in browser is

Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'webwork_odesk1'@'119.154.3.131' (using password: YES) in C:\xampp\htdocs\project\index.php on line 4

Couldn't make connection.

How I can fix this problem

  • 写回答

2条回答 默认 最新

  • doujia7094 2012-11-12 20:39
    关注

    See this similar thread.

    Like I said there, "Access denied for user 'webwork_odesk1'@'119.154.3.131' (using password: YES)"-messages come from two things - either hostname/username/password/database is wrong or the user doesn't have the required permissions. Check that user has the right permissions.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 python怎么在已有视频文件后添加新帧
  • ¥20 虚幻UE引擎如何让多个同一个蓝图的NPC执行一样的动画,
  • ¥15 fluent里模拟降膜反应的UDF编写
  • ¥15 MYSQL 多表拼接link
  • ¥15 关于某款2.13寸墨水屏的问题
  • ¥15 obsidian的中文层级自动编号
  • ¥15 同一个网口一个电脑连接有网,另一个电脑连接没网
  • ¥15 神经网络模型一直不能上GPU
  • ¥15 pyqt怎么把滑块和输入框相互绑定,求解决!
  • ¥20 wpf datagrid单元闪烁效果失灵