I have been trying to connect my registrationform with my sql database for a few days now. I've tried to find the issues in my code but eventually I went for a simple check if a connection was possible with the following code:
<?php
define('DB_HOST', '`............');
define('DB_NAME', '.............');
define('DB_USER', '..............');
define('DB_PASSWORD', '..........');
$con = mysql_connect(DB_HOST, DB_USER, DB_PASSWORD)
or die("Unable to connect to MySQL");
echo "Connected to MySQL<br>";
?>
Which always returns blank. This was equally the issue when I tried to connect my registrationform to the server.
Can someone maybe explain what could be wrong. I checked the DB host, name,username and password, so that can't be the problem.
thanks