This is shown on browser
Fatal error: Uncaught ArgumentCountError: mysqli_connect_errno() expects exactly 0 arguments, 1 given in C:\xampp\htdocs\Sports-Club-Management-System-master\Files\include\db_conn.php:11 Stack trace: #0 C:\xampp\htdocs\Sports-Club-Management-System-master\Files\include\db_conn.php(11): mysqli_connect_errno(Object(mysqli)) #1 C:\xampp\htdocs\Sports-Club-Management-System-master\Files\secure_login.php(3): include('C:\\xampp\\htdocs...') #2 {main} thrown in C:\xampp\htdocs\Sports-Club-Management-System-master\Files\include\db_conn.php on line 11
And this is my code on line 11 in db_conn
con = mysqli_connect($host, $username, $password, $db_name);
// Check connection
if (mysqli_connect_errno($con)) {
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
I would be more than happy for someone to see the whole project throughout to help me fix the problem, since I dont think it ends here, fingers crossed