I'm writing a php page that will connect to a mysql Db and insert a row. I have set up a user account with select and insert privlidges and I am using it to connect. If I use this account/pw to log on in a command shell it lets me log on but I cannot connect using the php script. My code looks as follows:
no matter what I try I always get the could not connect error. anyone had this problem before?
Code:
@ $db = mysql_pconnect("localhost","username","password");
if (!$db)
{
echo "Error: Could not connect to database. Please try again later.";
echo $quote;
echo $author;
exit;
}