locale=''; require 'includes/functions/functions.php'; define('WT_LOCALE', WT_I18N::init()); header('Content-Type: text/html; charset=UTF-8'); header($_SERVER["SERVER_PROTOCOL"].' 503 Service Temporarily Unavailable'); echo '', '', '', '', '', WT_WEBTREES, '', '', '', '', '

', WT_I18N::translate('This website is temporarily unavailable'), '

', '
', '

', WT_I18N::translate('Oops! The webserver is unable to connect to the database server. It could be busy, undergoing maintenance, or simply broken. You should try again in a few minutes or contact the website administrator.'), '

'; $config_ini_php=parse_ini_file('data/config.ini.php'); if (is_array($config_ini_php) && array_key_exists('dbhost', $config_ini_php) && array_key_exists('dbport', $config_ini_php) && array_key_exists('dbuser', $config_ini_php) && array_key_exists('dbpass', $config_ini_php) && array_key_exists('dbname', $config_ini_php)) { try { $dbh=new PDO('mysql:host='.$config_ini_php['dbhost'].';port='.$config_ini_php['dbport'].';dbname='.$config_ini_php['dbname'], $config_ini_php['dbuser'], $config_ini_php['dbpass'], array(PDO::ATTR_ERRMODE=>PDO::ERRMODE_EXCEPTION, PDO::ATTR_DEFAULT_FETCH_MODE=>PDO::FETCH_OBJ, PDO::ATTR_CASE=>PDO::CASE_LOWER, PDO::ATTR_AUTOCOMMIT=>true)); } catch (PDOException $ex) { echo '

', WT_I18N::translate('The database reported the following error message:'), '

'; echo '
', $ex->getMessage(), '
'; } } echo WT_I18N::translate('If you are the website administrator, you should check that:'); echo '
    '; echo '
  1. ', /* I18N: [you should check that:] ... */ WT_I18N::translate('the database connection settings in the file /data/config.ini.php are still correct'), '
  2. '; echo '
  3. ', /* I18N: [you should check that:] ... */ WT_I18N::translate('the directory /data and the file /data/config.ini.php have access permissions that allow the webserver to read them'), '
  4. '; echo '
  5. ', /* I18N: [you should check that:] ... */ WT_I18N::translate('you can connect to the database using other applications, such as phpmyadmin'), '
  6. '; echo '
'; echo '

', WT_I18N::translate('If you cannot resolve the problem yourself, you can ask for help on the forums at webtrees.net'), '

'; echo '
'; echo ''; echo '';