sasan223 Posted June 9, 2015 Share Posted June 9, 2015 I was trying to access my site, and the following errors appeared:how can I fix this?Warning: mysqli::mysqli(): (HY000/1045): Access denied for user 'atisonir_admin'@'localhost' (using password: YES) in /home/atisonir/public_html/classes/db/mysqli.class.php on line 30Warning: mysqli_options(): Couldn't fetch mysqli in /home/atisonir/public_html/classes/db/mysqli.class.php on line 32Fatal error: Access denied for user 'atisonir_admin'@'localhost' (using password: YES) in /home/atisonir/public_html/classes/db/mysqli.class.php on line 35 Quote Link to comment Share on other sites More sharing options...
havenswift-hosting Posted June 9, 2015 Share Posted June 9, 2015 HiThis simply means that the database username / password settings are not correct - so make sure that you set these to be the same as when you created the databaseIan Quote Link to comment Share on other sites More sharing options...
bsmither Posted June 9, 2015 Share Posted June 9, 2015 I ran into this after making a fresh install to a fresh database. Since it's all on a simulated production server, it is up to me to make sure that the database server has a username and password installed in its userbase. Generally, the hosting provider has the hosting control panel (cPanel?) manage this automatically.Then, that user must be permitted to access the database from certain locations: from anywhere, from a specific range of IP addresses, or from 'localhost'.The information cPanel gives you about accessing the database by your web app is all there. Then, in the database server, a database is created. The user is given permission to access that database. Again, all this is by the hosting provider or cPanel.So, the web app needs the name of the database, the name of the host where it is at, a username and a password. In the faulting installation, I had the user authorized to access the database from 'localhost' while my web app was calling the computer's IP address. Quote Link to comment Share on other sites More sharing options...
sasan223 Posted June 10, 2015 Author Share Posted June 10, 2015 thank to your comments, I changed the password of the database user, the problem solved. 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.