PHP needs a connection to talk to the database. On local XAMPP, the host is usually localhost, the user is root, and the password is typically empty. In production, though, secure credentials should be stored in an environment/config file.
php
<?php
$host = "localhost";
$user = "root";
$password = "";
$database = "thutatech_demo";
$conn = new mysqli($host, $user, $password, $database);
if ($conn->connect_error) {
die("Connection failed: " . $conn->connect_error);
}
echo "Database connected successfully.";
?>You should see
Database connected successfully.