diff --git a/add_bug.php b/add_bug.php new file mode 100644 index 0000000..95edad1 --- /dev/null +++ b/add_bug.php @@ -0,0 +1,76 @@ +prepare('INSERT INTO bugs (title, description, steps_to_reproduce) VALUES (?, ?, ?)'); + $stmt->execute([$title, $description, $steps_to_reproduce]); + header('Location: bugs.php'); + exit; + } catch (PDOException $e) { + $errors[] = 'Database error: ' . $e->getMessage(); + } + } +} +?> + + + + + + Add New Bug + + + + +
+

Add New Bug

+ + +
+ +

+ +
+ + +
+
+
+
+ + +
+
+ + +
+
+ + +
+
+ Cancel + +
+
+
+
+
+ + diff --git a/assets/vm-shot-2026-01-15T17-13-29-790Z.jpg b/assets/vm-shot-2026-01-15T17-13-29-790Z.jpg new file mode 100644 index 0000000..95071c6 Binary files /dev/null and b/assets/vm-shot-2026-01-15T17-13-29-790Z.jpg differ diff --git a/bugs.php b/bugs.php new file mode 100644 index 0000000..bf9c969 --- /dev/null +++ b/bugs.php @@ -0,0 +1,75 @@ +query('SELECT * FROM bugs ORDER BY created_at DESC'); +$bugs = $stmt->fetchAll(); +?> + + + + + + Bug Dashboard + + + + + +
+
+

Bug Dashboard

+ + Add New Bug + +
+ +
+
+ +
+

No bugs found.

+
+ +
+ + + + + + + + + + + + + + + + + + + +
TitleStatusCreated AtActions
+ + View + +
+
+ +
+
+
+ Back to Home +
+
+ + + + diff --git a/db/config.php b/db/config.php index 841566d..69601bd 100644 --- a/db/config.php +++ b/db/config.php @@ -5,6 +5,8 @@ define('DB_NAME', 'app_37487'); define('DB_USER', 'app_37487'); define('DB_PASS', '693524f4-8c9f-4c2d-8319-33438c0007b8'); +require_once __DIR__ . '/database.php'; + function db() { static $pdo; if (!$pdo) { @@ -15,3 +17,5 @@ function db() { } return $pdo; } + +create_schema(); diff --git a/db/database.php b/db/database.php new file mode 100644 index 0000000..c96371a --- /dev/null +++ b/db/database.php @@ -0,0 +1,57 @@ +exec($sql); + } catch (PDOException $e) { + die("DB ERROR: " . $e->getMessage()); + } +} diff --git a/index.php b/index.php index 7205f3d..2f2cce2 100644 --- a/index.php +++ b/index.php @@ -12,10 +12,10 @@ $now = date('Y-m-d H:i:s'); - New Style + Bug Tracker @@ -32,119 +32,25 @@ $projectImageUrl = $_SERVER['PROJECT_IMAGE_URL'] ?? ''; + -
-
-

Analyzing your requirements and generating your website…

-
- Loading… -
-

AI is collecting your requirements and applying the first changes.

-

This page will update automatically as the plan is implemented.

-

Runtime: PHP — UTC

-
+
+

Welcome to Your Bug Tracker

+

A simple application to track bugs and test cases.

+ Go to Bug Dashboard
-