Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- if (isset($_GET['vkey'])){
- //verification process
- $vkey = $_GET['vkey'];
- $mysqli = NEW MySQLi('localhost','root','','bookfly');
- $resultSet = $mysqli->query("SELECT verified, vkey FROM signuptable WHERE verified =0 and key = '$vkey'LIMIT 1");
- if($resultSet->num_rows == 1){
- //validated the email
- $update = $mysqli->query("UPDATE signuptable SET verified = 1 WHERE vkey='$vkey' LIMIT 1");
- if($update){
- echo "Your Account has been verified . You may login now.";
- }
- else{
- echo "$mysqli->error";
- }
- }
- else{
- echo "This account is invalid or already verified ";
- }
- }
- else
- {
- die("Something Went Wrong");
- }
- ?>
- <html lang="en">
- <head>
- <meta charset="UTF-8">
- <title>Title</title>
- </head>
- <body>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement