nitiphone2021
New member
According to I have a project need to use PHP 5.6.40 connect to mysql version 5.7.34
This URL for phpinfo()
http://newlink.bdb.com.la/app/webroot/test.php
when I try to connect it by below coding
it's show 500 internal error.
what should I check and fix this problem? it's private host, so I can run linux command to check
This URL for phpinfo()
http://newlink.bdb.com.la/app/webroot/test.php
when I try to connect it by below coding
Code:
$servername = "localhost";
$username = "user";
$password = "pass";
$db_database = 'db_unelr';
$db_port = '3306';
// Create connection
$conn = mysqli_connect($servername, $username, $password,$db_database,$db_port);
// Check connection
if ($conn->connect_error) {
die("Connection failed: " . $conn->connect_error);
}
echo "Connected successfully";
it's show 500 internal error.
what should I check and fix this problem? it's private host, so I can run linux command to check