bhq@iemsoft.cn
2018-11-27 e2b48dac099e43f4b3243cdf19a7522e4b5eccbe
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>{$lang.cp_home}{if $ur_here} - {$ur_here}{/if}</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link href="styles/general.css" rel="stylesheet" type="text/css" />
<link href="styles/main.css" rel="stylesheet" type="text/css" />
{literal}
<style type="text/css">
  body {
    color: white;
  }
</style>
{/literal}
{insert_scripts files="../js/utils.js,validator.js"}
<script language="JavaScript">
<!--
// 这里把JS用到的所有语言都赋值到这里
{foreach from=$lang.js_languages key=key item=item}
var {$key} = "{$item}";
{/foreach}
//-->
</script>
 
</head>
<body style="background: #278296">
 
{if $form_act eq "forget_pwd"}
<form action="get_password.php" method="post" name="submitAdmin" onsubmit="return validate()">
  <table cellspacing="0" cellpadding="0" style="margin-top: 100px" align="center">
  <tr>
    <td><img src="images/login.png" width="178" height="256" border="0" alt="" /></td>
    <td style="padding-left: 50px">
      <table>
        <tr>
          <td colspan="2"><h3>{$lang.get_newpassword}</h3></td>
        </tr>
        <tr>
          <td>{$lang.user_name}</td>
          <td>
            <input type="text" name="user_name" maxlength="20" size="30"/>{$lang.require_field}
          </td>
        </tr>
        <tr>
          <td>{$lang.email}</td>
          <td>
            <input type="text" name="email" size="30" />{$lang.require_field}
         </td>
        </tr>
       <tr>
         <td>&nbsp;</td>
         <td>
           <input type="hidden" name="action" value="get_pwd" />
           <input type="hidden" name="act" value="forget_pwd" />
           <input type="submit" value="{$lang.click_button}" class="button" />
           <input type="reset" value="{$lang.reset_button}" class="button" />
         </td>
       </tr>
      </table>
    </td>
  </tr>
  </table>
</form>
{/if}
{if $form_act eq "reset_pwd"}
<form action="get_password.php" method="post" name="submitPwd" onsubmit="return validate2()">
  <table cellspacing="0" cellpadding="0" style="margin-top: 100px" align="center">
  <tr>
    <td><img src="images/login.png" width="178" height="256" border="0" alt="" /></td>
    <td style="padding-left: 50px">
      <table>
        <tr>
          <td colspan="2"><h3>{$lang.get_newpassword}</h3></td>
        </tr>
        <tr>
          <td>{$lang.enter_admin_pwd}</td>
          <td>
            <input type="password" name="password" size="30"/>{$lang.require_field}
          </td>
        </tr>
        <tr>
          <td>{$lang.confirm_admin_pwd}</td>
          <td>
            <input type="password" name="confirm_pwd" size="30" />{$lang.require_field}
         </td>
        </tr>
       <tr>
         <td>&nbsp;</td>
         <td>
           <input type="hidden" name="action" value="reset_pwd" />
           <input type="hidden" name="act" value="forget_pwd" />
           <input type="hidden" name="adminid" value="{$adminid}" />
           <input type="hidden" name="code" value="{$code}" />
           <input type="submit" value="{$lang.click_button}" class="button" />
           <input type="reset" value="{$lang.reset_button}" class="button" />
         </td>
       </tr>
      </table>
    </td>
  </tr>
  </table>
</form>
{/if}
{literal}
<script type="text/javascript">
<!--
/**
* 检查表单输入的数据
*/
function validate()
{
  validator = new Validator("submitAdmin");
  validator.required("user_name", user_name_empty);
  validator.required("email", email_empty, 1);
  validator.isEmail("email", email_error);
 
  return validator.passed();
}
 
function validate2()
{
  validator = new Validator("submitPwd");
  validator.required("password",            admin_pwd_empty);
  validator.required("confirm_pwd",         confirm_pwd_empty);
  if (document.forms['submitPwd'].elements['confirm_pwd'].value.length > 0)
  {
    validator.eqaul("password","confirm_pwd", both_pwd_error);
  }
 
  return validator.passed();
}
//-->
</script>
{/literal}
</body>
</html>