Files
main-website/poker-paf/old/get_total_game_blind.php
T
2026-04-27 06:52:16 +00:00

19 lines
500 B
PHP

<?php
require_once 'db.php';
header('Content-Type: application/json');
$game_id = intval($_POST['game_id']);
try {
// 1. Récupérer la blind de la partie
$stmt = $db->prepare("SELECT pot FROM games WHERE id = ?");
$stmt->execute([$game_id]);
$game = $stmt->fetch();
$pot = $game['pot'];
echo json_encode(['success' => true, 'total_blind' => $pot]);
} catch (Exception $e) {
echo json_encode(['success' => false, 'message' => $e->getMessage()]);
}
?>