{template 'phpcms','header'}

<script language="javascript">
function checkform()
{
	if(document.myform.username.value=="")
	{
		alert("请输入用户名！");
		document.myform.username.focus();
		return false;
	}
	if(document.myform.password.value == "")
	{
		alert("请输入密码！");
		document.myform.password.focus();
		return false;
	}
<!--{if $MOD['enablecheckcodeoflogin']}-->
	if(document.myform.checkcodestr.value == "")
	{
		alert("请输入验证码！");
		document.myform.checkcodestr.focus();
		return false;
	}
<!--{/if}-->
    return true;
}
</script>
<table width="352" align="center" cellpadding="0" cellspacing="1" class="loginbox">
<form name="myform" method="post" action="{$MOD[linkurl]}login.php"  onsubmit="return checkform();">
  <tr>
    <td colspan="2"><img src="{$skindir}/images/login.gif" /></td>
	</tr>
  <tr>
    <td width="120" height="30" class="td_right">用户名：</td>
    <td><input name="username" type="text" id="username" size="15" style="width:120px">
       <a href="{$MOD[linkurl]}register.php" target="_blank" class="blue">立即注册</a></td>
  </tr>
  <tr>
    <td height="30" class="td_right">密　码：</td>
    <td><input name="password" type="password" id="password" size="15" style="width:120px" > <a href="{$MOD[linkurl]}getpassword.php" target="_blank" class="red">忘记密码</a> </td>
  </tr>
<!--{if $MOD['enablecheckcodeoflogin']}-->
    <tr>
      <td class="td_right">验证码：</td>
      <td>
      <input name="checkcodestr" type="text" style="width:120px">
	  <img src="{PHPCMS_PATH}checkcode.php" id="checkcode" onclick="this.src='{PHPCMS_PATH}checkcode.php?id='+Math.random()*5;" style="cursor:pointer;" alt="验证码,看不清楚?请点击刷新验证码" align="absmiddle"/>
      </td>
    </tr>
<!--{/if}-->
  <tr>
    <td height="30" class="td_right">Cookie：</td>
    <td><select name="cookietime" id="cookietime" style="width:120px">
          <option value="0">不保存</option>
          <option value="86400" {$select[86400]}>保存一天</option>
          <option value="2592000" {$select[2592000]}>保存一月</option>
          <option value="31536000" {$select[31536000]}>保存一年</option>
        </select></td>
  </tr>
  <tr>
    <td height="30"></td>
    <td>
      <input name="forward" type="hidden" id="forward" value="{$forward}">
      <input name="dosubmit" type="submit" id="dosubmit" size="15" value=" 登 录 " class="btn">
      <input name="reset" type="reset" id="reset  size="15" value=" 重 置 " class="btn">
</td>
  </tr>
</form>
</table>

{template 'phpcms','footer'}