change host to localhsot

This commit is contained in:
vadym Novoselskyi 2024-09-27 11:16:47 +02:00
parent fca9e1d060
commit 75928e80c5
3 changed files with 3 additions and 3 deletions

View File

@ -11,7 +11,7 @@ class dbEgyTalk
// Definierar konstanter med användarinformation.
define('DB_USER', 'egytalk');
define('DB_PASSWORD', '12345');
define('DB_HOST', 'mariadb');
define('DB_HOST', 'localhost');
define('DB_NAME', 'egytalk');
$dsn = 'mysql:host=' . DB_HOST . ';dbname=' . DB_NAME . ';charset=utf8';

View File

@ -6,7 +6,7 @@
define('DB_PASSWORD', '12345');
}
if (!defined('DB_HOST')) {
define('DB_HOST', 'mariadb'); // Use 'mariadb' for Docker, otherwise '127.0.0.1'
define('DB_HOST', 'localhost'); // Use 'mariadb' for Docker, otherwise '127.0.0.1'
}
if (!defined('DB_NAME')) {
define('DB_NAME', 'egytalk');

View File

@ -2,7 +2,7 @@
// Definierar konstanter med användarinformation.
define ('DB_USER', 'world');
define ('DB_PASSWORD', '12345');
define ('DB_HOST', 'mariadb'); // 'Om docker - 'mariadb', annars 127.0.0.1
define ('DB_HOST', 'localhost'); // 'Om docker - 'mariadb', annars 127.0.0.1
define ('DB_NAME', 'world');
// Skapar en anslutning till MySql och databasen world