Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- if(isset($_GET['email']) AND isset($_GET['pin'])){
- $email=$_GET['email'];
- $pin=$_GET['pin'];
- $search = mysql_query("SELECT email, aktifasi, status FROM usastb WHERE email='".$email."' AND aktifasi='".$pin."'") or die(mysql_error());
- $match = mysql_num_rows($search);
- if($match > 0){
- // We have a match, activate the account
- mysql_query("UPDATE usastb SET status='aktif' WHERE email='".$email."' AND aktifasi='".$pin."' AND status='pending'") or die(mysql_error());
- echo '<div class="statusmsg">Your account has been activated, you can now login</div>';
- }else{
- // No match -> invalid url or account has already been activated.
- }
- }
- ?>
Add Comment
Please, Sign In to add comment