gesf
New member
You won't get nothing, unless you make some output or condition for it.
That means that the connection function should return true (1) in case of success and false (0) otherwise. However you won't get true in success case but a MySQL link identifier. Anyway... a great way for you to know is running a query.
You also have a great example in the manual:
That means that the connection function should return true (1) in case of success and false (0) otherwise. However you won't get true in success case but a MySQL link identifier. Anyway... a great way for you to know is running a query.
You also have a great example in the manual:
Code:
<?php
$link = mysql_connect('localhost', 'mysql_user', 'mysql_password');
if(!$link) {
die('Could not connect: ' . mysql_error());
}
echo 'Connected successfully';
mysql_close($link);
?>