|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #24332 mysql_connect() are not pass a password
Submitted: 2003-06-25 07:17 UTC Modified: 2003-06-25 08:01 UTC
From: nefer at ib dot ru Assigned:
Status: Not a bug Package: MySQL related
PHP Version: 4.3.3RC1 OS: FreeBSD 4.8-CURRENT
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
Solve the problem:
27 + 35 = ?
Subscribe to this entry?

 [2003-06-25 07:17 UTC] nefer at ib dot ru
I can't connect to MySQL server, cose mysql_connect() are not pass a password to the server (i think).

mysql  Ver 11.18 Distrib 3.23.56, for portbld-freebsd4.8 (i386)

Reproduce code:
    mysql_connect('localhost', 'root', 'cccc');                                                                                                 
    echo mysql_error();                                                                                                                               

Expected result:
Nothing (as no error)

Actual result:
Access denied for user: 'root@localhost' (Using password: NO)


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2003-06-25 07:21 UTC]
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit as this bug system is not the
appropriate forum for asking support questions. 

Thank you for your interest in PHP.

Works fine, you must be doing something wrong.
 [2003-06-25 07:39 UTC] webmaster at ragnarokonline dot de
> (Using password: NO)
This means, no password has been set for the account

mysql_connect('localhost', 'root');

should work, then

  Christian Stadler
 [2003-06-25 07:50 UTC] nefer at ib dot ru
Password is set, when i use 'mysql -p' command all works fine.  I know that there is some similar troubles reported, but there is not my current problen. At now i'm downgrading to 4.3.2 version, cose i get problems after upgrading to 4.3.3RC1. ONLY! MySQL is stay untouched.
 [2003-06-25 08:01 UTC] nefer at ib dot ru
I'm downgraded to 4.3.2... Now it works. So i still think that this is PHP bug, no MySQL.
PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Sat Feb 04 18:03:44 2023 UTC