• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Making lost account send email

Axelor

Member
Joined
Sep 2, 2010
Messages
505
Reaction score
9
Hello Otlanders,

Looking for someone who can help me at fixing the lost account sending email for lost password.
It doesn't send any email. Giving

An error occorred while sending email! Try again or contact with admin.

I am willing to pay for the help.

You can contact me on discord: axelor#7936
 
If are you using Gesior Account, here is a code that does not require an email being sent out. This only requires Recovery Key to recover the account.

PHP:
<img class="Title"  src="/images/head/headline-lostaccount.png" alt="Contentbox headline" />
<?PHP header("Content-Type: text/html; charset=ISO-8859-1",true);
$link = '?subtopic=lostaccount';
$link2 = '?subtopic=accountmanagement';
$newplayer = new Player();
$newpassgesior = $newpassword;
$step = $_REQUEST['step'];


    
if($step == '')
    {
        $main_content .= '<B>Welcome to the Lost Account Interface!</B><BR><BR>
If you have lost access to your account, this interface can help you. Of course, you need to prove that your the owner of the account that is being recovered. Enter all required information and follow the instructions carefully. Please understand there is no way to gain access to your account if it is not registered.<br><br>
The first step to using the Lost Account Interface, enter the name of a lost account character, select the recovery option and click "Submit".<BR><BR>';
$main_content .= '<FORM ACTION="'.$link.'" METHOD=post> <INPUT TYPE=hidden NAME="character" VALUE="" /> <TABLE CELLSPACING=1 CELLPADDING=4 BORDER=0 WIDTH=100%>
        <TR><TD BGCOLOR="'.$config['site']['vdarkborder'].'" CLASS=white><B>Please enter the name of your character:</B></TD></TR> <TR><TD BGCOLOR="'.$config['site']['darkborder'].'">
        <INPUT TYPE=text NAME="nick" VALUE="" autocomplete="off" SIZE="26" MAXLENGTH="25"><BR> </TD></TR> </TABLE><br> <TABLE CELLSPACING=1 CELLPADDING=4 BORDER=0 WIDTH=100%>
        <TR><TD BGCOLOR="'.$config['site']['vdarkborder'].'" CLASS=white><B>Recovery Option:</B></TD></TR> <TR><TD BGCOLOR="'.$config['site']['darkborder'].'">
        <INPUT TYPE=radio NAME="step" VALUE="reckey" checked>I have the recovery key and I want to set a new password for my account.<BR> </TD></TR> </TABLE>
        <BR> <TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center>
        <INPUT TYPE=image NAME="Submit" ALT="Submit" SRC="'.$layout_name.'/images/buttons/sbutton_submit.gif" BORDER=0 WIDTH=120 HEIGHT=18></center> </TD></TR></FORM></TABLE>';
    }
    
    
    elseif($step == 'reckey')
    {
        $nick = stripslashes($_REQUEST['nick']);
        if(check_name($nick))
        {
            $player = $newplayer;
            $account = $newplayer;
            $player->find($nick);
            if($player->isLoaded())
            $account = $player->getAccount();
            
            if($account->isLoaded())
            {
                $account_key = $account->getCustomField('key');
                if(!empty($account_key))
                {
                    $main_content .= 'If you enter the recovery key correctly, you will see the form to set a new password for the account.<BR><br>
                    <FORM ACTION="'.$link.'" METHOD=post> <input type="hidden" name="step" value="newpass"/> <TABLE CELLSPACING=1 CELLPADDING=4 BORDER=0 WIDTH=100%>
                    <TR><TD BGCOLOR="'.$config['site']['vdarkborder'].'" CLASS=white><B>Please enter your recovery key.</B></TD></TR>
                    <TR><TD BGCOLOR="'.$config['site']['darkborder'].'"><INPUT TYPE=hidden NAME="nick" VALUE="'.$nick.'" autocomplete="off" MAXLENGTH="25" SIZE="26" readonly="readonly" />
                    Recovery Key:&nbsp;&nbsp;&nbsp;&nbsp;<INPUT TYPE=text NAME="key" VALUE="" autocomplete="off" MAXLENGTH="10" SIZE="11" /><BR></TD></TR></TABLE>
                    <BR><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <INPUT TYPE=image NAME="Submit" ALT="Submit" SRC="'.$layout_name.'/images/buttons/sbutton_submit.gif" BORDER=0 WIDTH=120 HEIGHT=18 /></center> </TD></TR></FORM></TABLE></TABLE>';
                }
                else {$main_content .= '<center>The character you have entered has no recovery key!</center><BR /><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></TABLE>';}
            }
            else {$main_content .= '<center>Character or character account: <b>'.$nick.'</b> does not exist.</center><BR /><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></TABLE>';}
        }
        else {$main_content .= '<center>Invalid character name. Please try a different character name!.</center><BR /><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></TABLE>';}       
}   
    
    elseif($step == 'newpass')
    {
        $rec_key = trim($_REQUEST['key']);
        $nick = stripslashes($_REQUEST['nick']);
        if(check_name($nick))
        {
            $player = $newplayer;
            $account = $newplayer;
            $player->find($nick);
            if($player->isLoaded())
            $account = $player->getAccount();
            
            if($account->isLoaded())
            {
                $account_key = $account->getCustomField('key');
                if(!empty($account_key))
                {
                    if($account_key == $rec_key)
                    {
                     $main_content .= '<script type="text/javascript">
                    
                     function validate_required(field,alerttxt)
                     {
                     with (field)
                     {
                     if (value==null||value==""||value==" ") {alert(alerttxt);return false;}
                     else {return true}
                     }
                     }

                     function validate_form(thisform)
                     {
                     with (thisform)
                     {
                                if (verifpass==1)
             {                               
                                 if (validate_required(passor,"Set your new password:")==false) {passor.focus();return false;}
     if (validate_required(passor2,"Repeat your new password:")==false) {passor2.focus();return false;}
     if (passor2.value!=passor.value) {alert(\'Passwords do not match!\');return false;}
                     }
                         }
                     }
                     </script>';
                        
                        $main_content .= 'Set a new password for your account.<BR><BR>
                        <FORM ACTION="'.$link.'" onsubmit="return validate_form(this)" METHOD=post>
                        <input type="hidden" name="step" value="changepass"/>
                        <INPUT TYPE=hidden NAME="character" VALUE=""> <TABLE CELLSPACING=1 CELLPADDING=4 BORDER=0 WIDTH=100%>
                        <script type="text/javascript">var verifpass=1;</script>
                        <TR><TD BGCOLOR="'.$config['site']['vdarkborder'].'" CLASS=white><B>Please set your new password</B></TD></TR>
                        <TR><TD BGCOLOR="'.$config['site']['darkborder'].'"> <INPUT TYPE=hidden NAME="nick" VALUE="'.$nick.'" autocomplete="off" SIZE="26" MAXLENGTH="25" readonly="readonly" />
                        New Password:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<INPUT id="passor" TYPE=password NAME="new_pass" VALUE="" autocomplete="off" SIZE="31" MAXLENGTH="30"><BR>
                     Repeat New Password:&nbsp;&nbsp;<INPUT id="passor2" TYPE=password NAME="new_pass2" VALUE="" autocomplete="off" SIZE="31" MAXLENGTH="30" ><BR>
                        <INPUT TYPE=hidden NAME="key" VALUE="'.$rec_key.'"> </TD></TR></TABLE> <BR><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center>
                        <INPUT TYPE=image NAME="Submit" ALT="Submit" SRC="'.$layout_name.'/images/buttons/sbutton_submit.gif" BORDER=0 WIDTH=120 HEIGHT=18></center> </TD></TR></FORM></TABLE></TABLE>';
                    }
                 else {$main_content .= '<center>Wrong recovery key.</center><BR /><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></TABLE>';}
             }
                else {$main_content .= '<center>The account has no recovery key!</center><BR /><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></TABLE>';}
            }
            else {$main_content .= '<center>Character or character account: <b>'.$nick.'</b> does not exist.</center><BR /><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></TABLE>';}
        }
        else {$main_content .= '<center>Invalid character name. Please try using another character name.</center><BR /><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></TABLE>';}       
}
    
    elseif($step == 'changepass')
    {
        $rec_key = trim($_REQUEST['key']);
        $nick = stripslashes($_REQUEST['nick']);
        $new_pass = trim($_POST['new_pass']);

        if(empty($new_pass)) {$main_content .= 'Enter your new password.';}
        if(empty($new_pass2)) {$main_content .= 'Account Details';}
        
        if(check_name($nick))
        {
            $player = $newplayer ;
            $account = $newplayer ;
            $player->find($nick);
            if($player->isLoaded())
            $account = $player->getAccount();
            
            if($account->isLoaded())
            {
                $account_key = $account->getCustomField('key');
                if(!empty($account_key))
                {
                    if($account_key == $rec_key)
                    {
                        if(check_password($new_pass))
                        {
                            $account->setPassword($newpassgesior);
                            $account->save();
                            $main_content .= '<BR> <FORM ACTION="'.$link2.'" onsubmit="return validate_form(this)" METHOD=post> <INPUT TYPE=hidden NAME="character" VALUE="">
                            <TABLE CELLSPACING=1 CELLPADDING=4 BORDER=0 WIDTH=100%> <TR><TD BGCOLOR="'.$config['site']['vdarkborder'].'" CLASS=white><B>Your account and your new password</B></TD></TR> <TR><TD BGCOLOR="'.$config['site']['darkborder'].'">
                            Account Name:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<b>'.$account->getName().'</b><BR>
                            New Password:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<b>'.$new_pass.'</b><BR></TD></TR></TABLE></FORM>';
                        }
                        else {$main_content .= '<center>Wrong password format. Use only a-Z, A-Z, 0-9.</center><br>';}
                    }
                    else {$main_content .= '<center>Wrong Recovery Key!</center><br>';}
                }
                else {$main_content .= '<center>The account has no recovery key!</center><br>';}
            }
            else {$main_content .= '<center>Character or character account: <b>'.$nick.'</b> does not exist.</center><BR />';}
        }
        else {$main_content .= '<center>Invalid character name. Please try using another character name.</center>';}
        
        $main_content .= '<TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></FORM></TABLE></TABLE>';
    }
?>
 
If are you using Gesior Account, here is a code that does not require an email being sent out. This only requires Recovery Key to recover the account.

PHP:
<img class="Title"  src="/images/head/headline-lostaccount.png" alt="Contentbox headline" />
<?PHP header("Content-Type: text/html; charset=ISO-8859-1",true);
$link = '?subtopic=lostaccount';
$link2 = '?subtopic=accountmanagement';
$newplayer = new Player();
$newpassgesior = $newpassword;
$step = $_REQUEST['step'];


   
if($step == '')
    {
        $main_content .= '<B>Welcome to the Lost Account Interface!</B><BR><BR>
If you have lost access to your account, this interface can help you. Of course, you need to prove that your the owner of the account that is being recovered. Enter all required information and follow the instructions carefully. Please understand there is no way to gain access to your account if it is not registered.<br><br>
The first step to using the Lost Account Interface, enter the name of a lost account character, select the recovery option and click "Submit".<BR><BR>';
$main_content .= '<FORM ACTION="'.$link.'" METHOD=post> <INPUT TYPE=hidden NAME="character" VALUE="" /> <TABLE CELLSPACING=1 CELLPADDING=4 BORDER=0 WIDTH=100%>
        <TR><TD BGCOLOR="'.$config['site']['vdarkborder'].'" CLASS=white><B>Please enter the name of your character:</B></TD></TR> <TR><TD BGCOLOR="'.$config['site']['darkborder'].'">
        <INPUT TYPE=text NAME="nick" VALUE="" autocomplete="off" SIZE="26" MAXLENGTH="25"><BR> </TD></TR> </TABLE><br> <TABLE CELLSPACING=1 CELLPADDING=4 BORDER=0 WIDTH=100%>
        <TR><TD BGCOLOR="'.$config['site']['vdarkborder'].'" CLASS=white><B>Recovery Option:</B></TD></TR> <TR><TD BGCOLOR="'.$config['site']['darkborder'].'">
        <INPUT TYPE=radio NAME="step" VALUE="reckey" checked>I have the recovery key and I want to set a new password for my account.<BR> </TD></TR> </TABLE>
        <BR> <TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center>
        <INPUT TYPE=image NAME="Submit" ALT="Submit" SRC="'.$layout_name.'/images/buttons/sbutton_submit.gif" BORDER=0 WIDTH=120 HEIGHT=18></center> </TD></TR></FORM></TABLE>';
    }
   
   
    elseif($step == 'reckey')
    {
        $nick = stripslashes($_REQUEST['nick']);
        if(check_name($nick))
        {
            $player = $newplayer;
            $account = $newplayer;
            $player->find($nick);
            if($player->isLoaded())
            $account = $player->getAccount();
           
            if($account->isLoaded())
            {
                $account_key = $account->getCustomField('key');
                if(!empty($account_key))
                {
                    $main_content .= 'If you enter the recovery key correctly, you will see the form to set a new password for the account.<BR><br>
                    <FORM ACTION="'.$link.'" METHOD=post> <input type="hidden" name="step" value="newpass"/> <TABLE CELLSPACING=1 CELLPADDING=4 BORDER=0 WIDTH=100%>
                    <TR><TD BGCOLOR="'.$config['site']['vdarkborder'].'" CLASS=white><B>Please enter your recovery key.</B></TD></TR>
                    <TR><TD BGCOLOR="'.$config['site']['darkborder'].'"><INPUT TYPE=hidden NAME="nick" VALUE="'.$nick.'" autocomplete="off" MAXLENGTH="25" SIZE="26" readonly="readonly" />
                    Recovery Key:&nbsp;&nbsp;&nbsp;&nbsp;<INPUT TYPE=text NAME="key" VALUE="" autocomplete="off" MAXLENGTH="10" SIZE="11" /><BR></TD></TR></TABLE>
                    <BR><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <INPUT TYPE=image NAME="Submit" ALT="Submit" SRC="'.$layout_name.'/images/buttons/sbutton_submit.gif" BORDER=0 WIDTH=120 HEIGHT=18 /></center> </TD></TR></FORM></TABLE></TABLE>';
                }
                else {$main_content .= '<center>The character you have entered has no recovery key!</center><BR /><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></TABLE>';}
            }
            else {$main_content .= '<center>Character or character account: <b>'.$nick.'</b> does not exist.</center><BR /><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></TABLE>';}
        }
        else {$main_content .= '<center>Invalid character name. Please try a different character name!.</center><BR /><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></TABLE>';}      
}  
   
    elseif($step == 'newpass')
    {
        $rec_key = trim($_REQUEST['key']);
        $nick = stripslashes($_REQUEST['nick']);
        if(check_name($nick))
        {
            $player = $newplayer;
            $account = $newplayer;
            $player->find($nick);
            if($player->isLoaded())
            $account = $player->getAccount();
           
            if($account->isLoaded())
            {
                $account_key = $account->getCustomField('key');
                if(!empty($account_key))
                {
                    if($account_key == $rec_key)
                    {
                     $main_content .= '<script type="text/javascript">
                   
                     function validate_required(field,alerttxt)
                     {
                     with (field)
                     {
                     if (value==null||value==""||value==" ") {alert(alerttxt);return false;}
                     else {return true}
                     }
                     }

                     function validate_form(thisform)
                     {
                     with (thisform)
                     {
                                if (verifpass==1)
             {                              
                                 if (validate_required(passor,"Set your new password:")==false) {passor.focus();return false;}
     if (validate_required(passor2,"Repeat your new password:")==false) {passor2.focus();return false;}
     if (passor2.value!=passor.value) {alert(\'Passwords do not match!\');return false;}
                     }
                         }
                     }
                     </script>';
                       
                        $main_content .= 'Set a new password for your account.<BR><BR>
                        <FORM ACTION="'.$link.'" onsubmit="return validate_form(this)" METHOD=post>
                        <input type="hidden" name="step" value="changepass"/>
                        <INPUT TYPE=hidden NAME="character" VALUE=""> <TABLE CELLSPACING=1 CELLPADDING=4 BORDER=0 WIDTH=100%>
                        <script type="text/javascript">var verifpass=1;</script>
                        <TR><TD BGCOLOR="'.$config['site']['vdarkborder'].'" CLASS=white><B>Please set your new password</B></TD></TR>
                        <TR><TD BGCOLOR="'.$config['site']['darkborder'].'"> <INPUT TYPE=hidden NAME="nick" VALUE="'.$nick.'" autocomplete="off" SIZE="26" MAXLENGTH="25" readonly="readonly" />
                        New Password:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<INPUT id="passor" TYPE=password NAME="new_pass" VALUE="" autocomplete="off" SIZE="31" MAXLENGTH="30"><BR>
                     Repeat New Password:&nbsp;&nbsp;<INPUT id="passor2" TYPE=password NAME="new_pass2" VALUE="" autocomplete="off" SIZE="31" MAXLENGTH="30" ><BR>
                        <INPUT TYPE=hidden NAME="key" VALUE="'.$rec_key.'"> </TD></TR></TABLE> <BR><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center>
                        <INPUT TYPE=image NAME="Submit" ALT="Submit" SRC="'.$layout_name.'/images/buttons/sbutton_submit.gif" BORDER=0 WIDTH=120 HEIGHT=18></center> </TD></TR></FORM></TABLE></TABLE>';
                    }
                 else {$main_content .= '<center>Wrong recovery key.</center><BR /><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></TABLE>';}
             }
                else {$main_content .= '<center>The account has no recovery key!</center><BR /><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></TABLE>';}
            }
            else {$main_content .= '<center>Character or character account: <b>'.$nick.'</b> does not exist.</center><BR /><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></TABLE>';}
        }
        else {$main_content .= '<center>Invalid character name. Please try using another character name.</center><BR /><TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></TABLE>';}      
}
   
    elseif($step == 'changepass')
    {
        $rec_key = trim($_REQUEST['key']);
        $nick = stripslashes($_REQUEST['nick']);
        $new_pass = trim($_POST['new_pass']);

        if(empty($new_pass)) {$main_content .= 'Enter your new password.';}
        if(empty($new_pass2)) {$main_content .= 'Account Details';}
       
        if(check_name($nick))
        {
            $player = $newplayer ;
            $account = $newplayer ;
            $player->find($nick);
            if($player->isLoaded())
            $account = $player->getAccount();
           
            if($account->isLoaded())
            {
                $account_key = $account->getCustomField('key');
                if(!empty($account_key))
                {
                    if($account_key == $rec_key)
                    {
                        if(check_password($new_pass))
                        {
                            $account->setPassword($newpassgesior);
                            $account->save();
                            $main_content .= '<BR> <FORM ACTION="'.$link2.'" onsubmit="return validate_form(this)" METHOD=post> <INPUT TYPE=hidden NAME="character" VALUE="">
                            <TABLE CELLSPACING=1 CELLPADDING=4 BORDER=0 WIDTH=100%> <TR><TD BGCOLOR="'.$config['site']['vdarkborder'].'" CLASS=white><B>Your account and your new password</B></TD></TR> <TR><TD BGCOLOR="'.$config['site']['darkborder'].'">
                            Account Name:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<b>'.$account->getName().'</b><BR>
                            New Password:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<b>'.$new_pass.'</b><BR></TD></TR></TABLE></FORM>';
                        }
                        else {$main_content .= '<center>Wrong password format. Use only a-Z, A-Z, 0-9.</center><br>';}
                    }
                    else {$main_content .= '<center>Wrong Recovery Key!</center><br>';}
                }
                else {$main_content .= '<center>The account has no recovery key!</center><br>';}
            }
            else {$main_content .= '<center>Character or character account: <b>'.$nick.'</b> does not exist.</center><BR />';}
        }
        else {$main_content .= '<center>Invalid character name. Please try using another character name.</center>';}
       
        $main_content .= '<TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%><TR><TD><center> <a href="'.$link.'" border="0"><IMG SRC="'.$layout_name.'/images/buttons/sbutton_back.gif" NAME="Back" ALT="Back" BORDER=0 WIDTH=120 HEIGHT=18></a></center> </TD></TR></FORM></TABLE></TABLE>';
    }
?>
Im using MYAAC.
 
Back
Top