2 Commits

Author SHA1 Message Date
luptmoor
573ed034dd added comments for slug as env var 2026-04-23 09:28:35 +02:00
luptmoor
3fb3ecbe52 SSL mode changed to disable 2026-04-22 16:08:23 +02:00
3 changed files with 3 additions and 3 deletions

View File

@@ -37,7 +37,7 @@ if ($page === 'logout') {
// -----------------------------------------------------------------
$pdo = get_db();
$stmt = $pdo->prepare("SELECT * FROM municipalities WHERE slug = :slug");
$stmt->execute([':slug' => 'lohne']);
$stmt->execute([':slug' => 'lohne']); # TODO: add slug as env var
$municipality = $stmt->fetch();
// Show Login Page if not authenticated

View File

@@ -33,7 +33,7 @@ try {
PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC,
PDO::ATTR_EMULATE_PREPARES => false
];
$dsn = "pgsql:host=$host;dbname=$db;port=$port";
$dsn = "pgsql:host=$host;dbname=$db;port=$port;sslmode=disable";
$pdo = new PDO($dsn, $user, $pass, $opt);

View File

@@ -14,7 +14,7 @@ require_once __DIR__ . '/api/db.php';
// -----------------------------------------------------------------
$pdo = get_db();
$stmt = $pdo->prepare("SELECT * FROM municipalities WHERE slug = :slug");
$stmt->execute([':slug' => 'lohne']);
$stmt->execute([':slug' => 'lohne']); # TODO: add slug as env var
$municipality = $stmt->fetch();
if (!$municipality) {