1
0
mirror of https://gitlab.com/animath/si/plateforme.git synced 2025-06-25 15:37:27 +02:00

Initial commit

This commit is contained in:
galaxyoyo
2019-08-21 22:56:46 +02:00
commit 311cb66cdd
36 changed files with 2698 additions and 0 deletions

View File

@ -0,0 +1,26 @@
<?php
include 'config.php';
$token = $_GET["token"];
if (isset($token)) {
$result = $DB->query("SELECT `email` FROM `users` WHERE `confirm_email` = '$token' AND `year` = '$YEAR';");
if (($data = $result->fetch()) === FALSE)
$error_message = "Le jeton est invalide. Votre compte est peut-être déjà validé ?";
else {
$DB->exec("UPDATE `users` SET `confirm_email` = NULL WHERE `confirm_email` = '$token';");
$error_message = "Votre adresse mail a été validée ! Vous pouvez désormais vous connecter.";
}
}
else {
$error_message = "Il n'y a pas de compte à valider !";
}
?>
<?php include "header.php" ?>
<h2><?php echo $error_message ?></h2>
<?php include "footer.php" ?>