Hello to all, first of all I'm new here and would like to ask a question that has been bugging me for days. It seems that whenever I try to connect with either
PHP Code:
mysql_connect(); 
or
PHP Code:
mysqli_connect(); 
I get somewhat the same error, either its showing 3 or 1, in the case I'm using the script now it shows all three, the errors are:

Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'user'@'localhost' (using password: YES) in on line 30

Warning: mysql_select_db() [function.mysql-select-db]: Access denied for user 'user'@'localhost' (using password: NO) in on line 31

Warning: mysql_select_db() [function.mysql-select-db]: A link to the server could not be established in on line 31
Access denied for user 'gogutaro'@'localhost' (using password: NO)

. Here is the code if it helps in any way:
PHP Code:
<?php
$host
='localhost';
$user='';
$password='';
$database="";
mysql_connect($host,$user,$password);
mysql_select_db($database) or die(mysql_error());

mysql_close();
?>
I am very desperate to fix the database connection thing since it has stopped me from doing my work and because of it I would love an answer from someone with more experience than I at web programming. Also the server I am using as I mentioned above is LiteSpeed and not Apache.