prepare("INSERT INTO parties (id, election_id, name, description) VALUES (?, ?, ?, ?)"); $stmt->execute([$id, $election_id, $name, $description]); audit_log('Added party', 'parties', $id); header("Location: ../candidate_management.php?success=1"); exit; } catch (Exception $e) { die($e->getMessage()); } }