The Nineteenth Executive Posted June 24, 2012 Share Posted June 24, 2012 Hi, I am using PHP and MySQL 5.0.19-nt - I want to use mysql_pconnect("localhost", "user", "password") for connection, but I can use only blank passwords (like mysql_pconnect("localhost", "user", "") ) -> connection is OK. But when I use normal non-blank password -> I cant connect to database (error msg). what is the setting for enabling normal passwords ? thanks Quote Link to comment Share on other sites More sharing options...
requinix Posted June 24, 2012 Share Posted June 24, 2012 Did you set a password on the account? And due diligence: are you sure you need a persistent connection? You've looked into what it entails? Quote Link to comment Share on other sites More sharing options...
The Nineteenth Executive Posted June 24, 2012 Author Share Posted June 24, 2012 yes, I set the password correctly in DB persistent connection is used in example from the book I am just studying, so I need to know why default login / password combo doesnt work. It is because of password (password set to blank in DB works), but I dont know how to change it to accept also normal passwords (for correctly working example and for later use). Quote Link to comment Share on other sites More sharing options...
requinix Posted June 25, 2012 Share Posted June 25, 2012 You don't have to "change it" to make it work with passwords. It already does. If it doesn't like the password then it's MySQL that doesn't like it, not mysql_pconnect(). Either a) You're not setting the password on the right user/host combination, or b) The password change hasn't been applied (like through a restart or a FLUSH PRIVILEGES) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.