简体   繁体   中英

I am getting following error while connecting to my database

I am getting following error while connecting to my database:

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator at admin@main-hosting.eu to inform them of the time this error occurred, and the actions you performed just before this error.

More information about this error may be available in the server error log.

php_error.log file:

[25-Feb-2017 09:45:09 UTC] PHP Warning: mysqli_connect(): (HY000/2003): Can't connect to MySQL server on 'mysql.hostinger.in' (4 "Interrupted system call") in /home/u191892126/public_html/API/connect.php on line 8

My php file:

<?php
$servername = "mysql.hostinger.in";//var deceleration I tried "localhost" too
$username = "u1918921**_root";
$password = "*********";
$dbname = "u191892126_acare";

// Create connection
$conn = mysqli_connect($servername, $username, $password, $dbname);
// Check connection
if (!$conn) {
    die("Connection failed: " . mysqli_connect_error());
}
?>

这是服务器的错误再次尝试(花了 4 小时),一切正常。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM