I have no problem connecting to a database using PHP however in some scripts I have tested, I have seen a small difference in the connect command.
What is the differenc
If don't use any option something like this;
if ("I'm just making test on my srv") {
error_reporting(E_ALL);
} else {
error_reporting(0);
}
Then, it could be recommended for this situation;
$conn = @mysql_connect(...);
if ($conn === false) {
// handle error
}
Or;
@mysql_connect(...) or die("Could not connect to ...");
So, @ suppresses the error if it exist at the line "where the suppressible function is used".
// Suppressible? Yes, cos you can not apply @ to die, exit, eval ... functions if these are structural functions.