From 41c86ecc086f4f273f0924624283a9d5d38a00a0 Mon Sep 17 00:00:00 2001 From: TigerStable Date: Fri, 12 Jun 2026 18:52:20 +0700 Subject: [PATCH] update db connection for production and add init_db.php --- api/db.php | 8 ++++---- api/init_db.php | 20 ++++++++++++++++++++ 2 files changed, 24 insertions(+), 4 deletions(-) create mode 100644 api/init_db.php diff --git a/api/db.php b/api/db.php index 273cbf5..ba8d969 100644 --- a/api/db.php +++ b/api/db.php @@ -1,8 +1,8 @@ exec($sql); + echo "Database table 'features' created successfully."; +} catch (PDOException $e) { + echo "Error creating table: " . $e->getMessage(); +} +?>