How to connect to '' MySQL Server

I am quite new to PHP and MySQl and making my progress. I have installed a MySQL server on my PC and wrote the PHP scripts for storing and retrieving the data from my MySQL Server. Everything works fine on my localhost [PC].

For the information I have used mysqli_connect(); to connect to my localhost MySQL Server.

Now my question is how can I connect to the ‘’ MySQL Server, I used the same username = ‘au2951***’ and password = ‘*******’ which has been sent during the registration and the host name = ‘’.

Like: mysql_connect(‘’,‘au2951***’, ‘*****’);

But I am getting the error as shown below:

" Warning: mysql_connect() [function.mysql-connect]: Access denied for user ‘au2951***’@‘’ (using password: YES) in /home/au2951***/public_html/mailinglist/php/addemail.php on line 15 "

It would be really helpful if any one have an idea of where I am going wrong.


The following is an example showing my DB connection script:

$conn = mysql_connect(“”, “a3367xxx_test”,"******") or die(mysql_error());
mysql_select_db(“a3367xxx_test”, $conn);

If you are using mysqli_connect(), the function should include also db_name as shown below:

$conn = mysqli_connect(“”, “a3367xxx_test”,"******", “a3367xxx_test”) or die(mysql_error());

The above code was written based on the following image:

Hi Grace1004,
thank you very much for the information. That really helped me.