jbingman Posted September 14, 2007 Share Posted September 14, 2007 how do i find out where my mysql database is? like when it says <?php //mysql info $host = "?"; $username = "*myusername*"; $password = "*mypassword*"; $database_name = "adminUser"; ?> Quote Link to comment https://forums.phpfreaks.com/topic/69409-solved-database-location/ Share on other sites More sharing options...
BlueSkyIS Posted September 14, 2007 Share Posted September 14, 2007 it's usually localhost, but you'll have to ask your server administrator to know for sure. Quote Link to comment https://forums.phpfreaks.com/topic/69409-solved-database-location/#findComment-348714 Share on other sites More sharing options...
jbingman Posted September 14, 2007 Author Share Posted September 14, 2007 yeah localhost is for the computer your on right? not a server that you dont own? Such as I'm hosted through bluehost.com. Quote Link to comment https://forums.phpfreaks.com/topic/69409-solved-database-location/#findComment-348718 Share on other sites More sharing options...
marcus Posted September 14, 2007 Share Posted September 14, 2007 It's localhost. Quote Link to comment https://forums.phpfreaks.com/topic/69409-solved-database-location/#findComment-348719 Share on other sites More sharing options...
jbingman Posted September 15, 2007 Author Share Posted September 15, 2007 ok, but whenever i try this. it gives me an error saying 'username'@'localhost' couldnt not be found. i realize this is a common error but i dont understand what im doing wrong. Quote Link to comment https://forums.phpfreaks.com/topic/69409-solved-database-location/#findComment-348899 Share on other sites More sharing options...
jagat21 Posted September 15, 2007 Share Posted September 15, 2007 You can check in your hosting panel that if any database user is created for accessing the databases on your server. And if the database user is created on your database server, then check that its assign to the database you are using. Quote Link to comment https://forums.phpfreaks.com/topic/69409-solved-database-location/#findComment-348902 Share on other sites More sharing options...
jbingman Posted September 15, 2007 Author Share Posted September 15, 2007 yeah theres a database and a username in that database but it gives me the Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'admin'@'localhost' (using password: YES) in /home/fresnosa/public_html/admin/index.php on line 18 Could not connect: Access denied for user 'admin'@'localhost' (using password: YES) Error everytime i click submit. Quote Link to comment https://forums.phpfreaks.com/topic/69409-solved-database-location/#findComment-348904 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.