public function validar_token($token) { $c_sql = new Sql(); $c_sql->conn_bd(); $ultimo_id = Token::ult_id_token(); $token_valido = "control:" . $ultimo_id; //b9ee0aab4a07f4b062182214a82758c // echo "<script>alert('".md5($token_valido)." - $token');</script>"; if (md5($token_valido) == $token) { return true; } return false; }
<?php include_once 'model/class_token.php'; ?> <html> <head> <title><?php echo Token::ult_id_token(); ?> </title> </head> <body> </body> </html>