{include file="header.tpl"}

{literal}
<script type="text/javascript">
function checkform() {
  if (document.forgotform.email.value == '') {
    alert("Please type your username or email!");
    document.forgotform.email.focus();
    return false;
  }
  return true;
}
</script>
{/literal}
<div class="box">
<div class="box_title" id="tba">Password Remind</div>
<div class="box_body">

{if $frm.display == 'confirmation_sent'}
<div style="color:green">Confirmation link was sent to your e-mail address. Please follow the link to reset your password.</div>
{elseif $frm.display == 'password_sent'}
<div style="color:green">Your login info was sent to your e-mail. You can <a href="{"?a=login"|encurl}">login</a> now.</div>
{elseif $frm.display == 'invalid_code'}
<div style="color:red">The code you have provided is invalid. It means you have used broken link or password was already sent to you.</div>
{else}

{if $errors}
<ul style="color:red">
{if $errors.turing}<li> Invalid turing image.</li>{/if}
{if $errors.no_input}<li> Please enter your username or e-mail addresss.</li>{/if}
</ul>
{/if}


<form method="post" name="forgotform" onsubmit="return checkform()" action="">
<input type=hidden name=a value="forgot_password">
<input type=hidden name=action value="forgot_password">
<table width="100%" border="0" cellspacing="1" cellpadding="3">
<tr>
 <td>Username or E-mail:</td>
 <td><input type=text name="email" class="inpts" size="45"></td>
</tr>
{if $settings.use_turing}
<tr>
  <td><img src="{"?a=turing&`$sesname`=`$sesid`&r=`$rand`"|encurl}" alt="turing code"></td>
  <td><input type=text name="turing" maxlength="6" size="10" class="inpts"></td>
</tr>
{/if}
<tr>
 <th></th>
 <td><input type=submit value="Remind" class="sbmt"></td>
</tr>
</table>
</form>
{/if}
</div></div>
{include file="footer.tpl"}
