I installed WAMP server few hours ago into my Windows 10 64-bit computer. I used phymyadmin to create a d
In the newer versions of Wampserver, the port for MySQL has changed from 3306
to 3308
(you can see it in your first screenshot). You will need to update your connection to specify that port. Otherwise you will be hitting the MariaDB installed with WAMP which does not have that database within it.
define('DB_SERVER', 'localhost');
define('DB_USERNAME', 'root');
define('DB_PASSWORD', '');
define('DB_NAME', 'testdb');
define('DB_PORT', 3308);
$link = mysqli_connect(DB_SERVER, DB_USERNAME, DB_PASSWORD, DB_NAME, DB_PORT);
As pointed out in the comments, it is also possible to make MySQL your default database which would also solve your problem. You can get the instructions from the DBA Stack Exchange site.