Okay, here is the problem. I have made a database for my site called Site. I have made two tables, and a few colums in each table, to store data on members for my site. The script is suppost to connect to MySQL database, and place the data in the correct tables and colums. I have set up a user for for this script. The user is siteuser identified by the password siteuser (I will change this later).
This is what the user's privlegies are, for that entire database...
(I got this using the show frants for siteuser; command)
It says:
GRANT USAGE ON . TO 'siteuser'@'%' IDENTIFIED BY PASSWORD '04d0daa20a38e6fe'
GREANT SELECT, INSERT, UPDATE ON Site.* TO 'siteuser'@'%'
Then I have this PHP code to connect to the database:
$Iconnection = mysql_pconnect("192.168.1.250","siteuser","siteuser");
if (!$Iconnection) {
echo "<b>ERROR:</b> Cannot connect to the database<br>";
}
I always get an error:
Warning: Access denied for user: 'siteuser@localhost' (Using password: YES) in /home/mark/public_html/functions.php on line 5
And then my own error:
ERROR: Cannot connect to the database
Why is this happining?