<?php

if (core::ifPost("from") AND core::getPost("from") == "validator" AND session::isConnect()) { 
    if(event::checkUrl(core::getPost("qRcode")) != DOMAIN_CONTROL){
        alert::recError("Le QR-Code n'est pas valide.");
        header("Location: /");
        exit();   
    } else { 
        header("Location: ".core::getPost("qRcode"));
    }
} else {
    header('HTTP/1.0 401 Unauthorized');
    exit();
}
