Why PHP MySql connection do not work?
I'm using MySQL given from A2Hosting. There I can create users and add them to databases. And i hosted my php codes inside web folder in symfony php structure. I dont want to use any symfony commands or functions. I have my own php calls to DB. But my Php codes gives the following error. But the user names and passwords are correct.
Query failed : Access 开发者_如何学编程denied for user 'games_user'@'localhost'
to database 'games'
Granting privileges to user 'games_user' could not be enough. You must grant privileges to 'games_user'@'localhost', specifiying the host, even for localhost.
Granting all privileges for instance should look like this:
GRANT ALL PRIVILEGES ON database.* TO 'games_user'@'localhost' IDENTIFIED BY 'password';
Check permissions for user "games_user" in your "games" database. Access is denied to database "games"
精彩评论