шаг 3 завершен

This commit is contained in:
Alisa
2026-06-04 00:27:17 +03:00
parent 420e67c9bd
commit 62ce8c4d01
27 changed files with 1565 additions and 42 deletions
+2 -16
View File
@@ -2,22 +2,8 @@
declare(strict_types=1);
use App\Core\Database;
use App\Controllers\HomeController;
require_once dirname(__DIR__) . '/app/bootstrap.php';
$dbStatus = 'not_checked';
try {
Database::pdo()->query('SELECT 1');
$dbStatus = 'connected';
} catch (Throwable $exception) {
$dbStatus = app_env('APP_DEBUG', 'false') === 'true'
? 'error: ' . $exception->getMessage()
: 'error';
}
view('pages/home', [
'title' => 'Рыбсток',
'dbStatus' => $dbStatus,
]);
(new HomeController())->index();