Jump to content

Trouble Connecting to Database


gerhardtdesign

Recommended Posts

Never worked with GoDaddy before... Can't get my config script to connect to the database.  Here's my code (I'm sure all the login info is correct, except maybe the host name but I copied that from GoDaddy too...)

<?php
ob_start();
// MySQL connection settings
$db_host = "anakdesigns.db.2089823.hostedresource.com";
$db_user = "********";
$db_pass = "********";
$db_name = "********";
// Connect to the database
$con = mysql_connect($db_host, $db_user, $db_pass) or die("Cannot connect to DB");
mysql_select_db($db_name) or die("Error accessing DB");
?>

 

http://www.anakdesigns.com/dev

 

Link to comment
https://forums.phpfreaks.com/topic/223010-trouble-connecting-to-database/
Share on other sites

Client does not support authentication protocol requested by server; consider upgrading MySQL client

 

Yep, I am fairly new to PHP so I am reading lots of books on it and getting better but that's one thing I'm sure I won't forget from here on out.  Thanks for the help.  I'll look up different methods of connecting.  No need for anymore sarcasm for me!

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.