Hi,

I'm developing a web application using mysqld as a localhost but
accessed from anywhere. My problem is simple, after entering form
data, and execute the php script, always returns an error I wrote in
case of unsuccesful connection to the db.

I did everything , create a user with many privileges, then flushed
the privileges, if I use PhpMyAdmin to access the db I have no
problems, the error happens when I use my program, what can be wrong

here are the lines I use to connect to the db and display error
message:

@ $db = mysql_pconnect("localhost", "testdb", "test123");
if (!$db)
{
 echo "Error: could not connect to database. Please try again later.";
 exit;
}
mysql_db("mydb");
...

What can be wrong ?
I'm starting to learn both php and mysql and I still can't understand
why this happened.

Regards,
Rick

AmpaSA Engineering




---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to