window.location="'.$url.'";';
exit;
}
if(isset($_GET['action'])&&$_GET['action']=="reset" &&empty($_GET['id'])){?>
Password reset
var id="'.$_GET['id'].'";';
$query=$bdd->prepare('SELECT user_id FROM users WHERE idvalidation=:id');//get the id
$query->bindValue(':id',$_GET['id'],PDO::PARAM_STR);
$query->execute();
$id=$query->fetch();
$query->CloseCursor();
if(!empty($id)){?>
Password reset