<!--{template 'default/head'}-->
<script language=javascript>
function checkuser()
{
   if ($('username').value.trim() == ""){
       alert("请输入您的用户名!");
       $('username').focus();
       return false ;
   }   
   if ($('email').value.trim() == ""){
       alert("请输入您注册时使用的邮箱!");
       $('email').focus();
       return false ;
   }   
   $('btn_submit').disabled = true;
   return true;
}

function checkpassword(){
   if($('password').value.trim() == ""){
      alert("请输入密码");
      $('password').value="";
      $('password').focus();
      return false;
   }
   if($('password').value.trim() != $('pwdconfirm').value.trim()){
      alert("两次密码不一致!");
      $('password').focus();
      $('password').value = $('pwdconfirm').value="";
      return false;
   }  
   $('btn_submit').disabled = true;
   return true;
}

</script>
<div class="cbody">
	<!--{if $step==1}-->
	<form class="label login" method="post"  name="ajaxForm" id="ajaxForm"  action="user.php?ac=password&step=2" onSubmit="return checkuser();">
		<p><label class="f-label">用户名</label><input class="f-text" name="username" type="text" id="username" size="30" /></p>
		<p><label class="f-label">注册时使用的邮箱</label><input class="f-text" name="email" type="text" id="email" size="30" /></p>
		<p class="note"><input type="submit"  value=" 下一步 " class="f-button" id="btn_submit" /></p>
	<!--{elseif $step==3}-->
	<form class="label login" method="post"  name="ajaxForm" id="ajaxForm" action="user.php?ac=password&step=3&verify={$verify}" onSubmit="return checkpassword();">
		<p><label class="f-label">新密码</label><input class="f-text" name="password" type="password" id="password" /></p>
		<p><label class="f-label">确认一下</label><input class="f-text" name="pwdconfirm" type="password" id="pwdconfirm" /></p>
		<p class="note">
			<input type="hidden" name="myFormAc" value="update" />
			<input type="submit"  value=" 修改密码 " class="f-button"  id="btn_submit" />
		</p>
	<!--{/if}-->
	</form>
</div>
<!--{template 'default/foot'}-->