enter image description hereI'm trying to connect replit.com (the cloud based IDE I'm using) and database from remotemysql.com. I only get "HTTP ERROR 500". How do I fix this? Any reply may help. Thanks.
Here is my code on mysqli_connect.php file (I hided username, dbname and password):
<?php 
$host = "remotemysql.com"; 
$user = "xxxxxxxxx"; 
$pass = "xxxxxxxxx"; 
$db = "xxxxxxxxx"; 
$port = 3306; 
//problem on this line below
$connection = mysqli_connect($host, $user, $pass, $db, $port); 
if(mysqli_connect_errno()) { 
die("Database connection failed: " . mysqli_connect_error() . " (" .mysqli_connect_errno() . ")" ); 
} else { 
echo "connection made"; 
} 
?>