a
This commit is contained in:
parent
bc23a2c8c6
commit
906485dc42
|
|
@ -307,8 +307,7 @@
|
|||
|
||||
<!-- Contestation Form -->
|
||||
<form action="<?= $action ?>" method="post">
|
||||
<!-- <input type="hidden" id="csrf_token" name="csrf_token" value="<?= htmlspecialchars($token) ?>"> -->
|
||||
<input class="form-control" type="text" id="csrf_token" name="csrf_token" value="<?= htmlspecialchars($token) ?>">
|
||||
<input type="hidden" id="csrf_token" name="csrf_token" value="<?= htmlspecialchars($token) ?>">
|
||||
|
||||
<div class="mb-4">
|
||||
<label for="motifContestation" class="form-label required">
|
||||
|
|
|
|||
|
|
@ -197,6 +197,10 @@
|
|||
</head>
|
||||
<body class='bg-light'>
|
||||
<div class='error-container'>
|
||||
|
||||
<!-- <input type='hidden' id='csrf_token' name='csrf_token' value='<?= htmlspecialchars($token) ?>'> -->
|
||||
<input class='form-control' type='text' id='csrf_token' name='csrf_token' value='<?= htmlspecialchars($token) ?>'>
|
||||
|
||||
<div class='error-card'>
|
||||
<div class='text-center mb-3'>
|
||||
<i class='bi bi-exclamation-triangle-fill text-danger' style='font-size: 3rem;'></i>
|
||||
|
|
|
|||
|
|
@ -57,8 +57,7 @@ function afficherMessage($message, $estErreur = true) {
|
|||
exit();
|
||||
}
|
||||
|
||||
|
||||
var_dump($_POST);
|
||||
// var_dump($_POST);
|
||||
|
||||
if (!isset($_POST['csrf_token'])) {
|
||||
afficherMessage("<strong>Mauvaise session!</strong>");
|
||||
|
|
@ -68,12 +67,10 @@ $csrf_token = trim($_POST['csrf_token']);
|
|||
|
||||
if (!Csrf::validateToken($csrf_token)) {
|
||||
afficherMessage("<strong>Mauvaise session!</strong>");
|
||||
// exit;
|
||||
}
|
||||
|
||||
echo "On peut maintenant contester";
|
||||
exit;
|
||||
|
||||
// echo "On peut maintenant contester";
|
||||
// exit;
|
||||
|
||||
// Configuration de la langue
|
||||
if (!isset($_SESSION['codeLangue'])) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user