June 13, 201016 yr I'm uploading a site to godaddy for a client and have successfully made a database but am not sure how to connect to the database in godaddy. I know in the local machine at home I use localhost username and password but what about the msql_connect info for godaddy. Can't seem to find the data anywhere would really appreciate your help thanks
June 13, 201016 yr I'm uploading a site to godaddy for a client and have successfully made a database but am not sure how to connect to the database in godaddy. I know in the local machine at home I use localhost username and password but what about the msql_connect info for godaddy. Can't seem to find the data anywhere would really appreciate your help thanks Something like this should work, providing you have all the details $dbhost = "yours.secureserver.net"; $dbuser = "user"; $dbpass = "pass"; $dbname = "name"; $db = mysql_connect($dbhost,$dbuser,$dbpass); mysql_select_db($dbname); echo mysql_error();
August 11, 201016 yr I used to use Godaddy. Do NOT use localhost. Go into the database with phpMyAdmin and then get the server location from there at the top. It'll look like what pat24 put up.
Create an account or sign in to comment