login.php源代码分析

<html>

<head>

<title></title>

<meta http-equiv="Content-Type" content="text/html; charset=gb2312">

<link href="../css/style.css" rel="stylesheet">

</head>

<body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">

<p>&nbsp;</p>

<p>&nbsp;</p>

<p>&nbsp;</p>

<script language="javascript">

 function chkinput(form){

   if(form.name.value==""){

 alert("请输入用户名!");

 form.name.select();

 %如果用户名为空,则将焦点定位在用户名输入框。

 return(false);

 %返回假

}

if(form.pwd.value==""){

 alert("请输入用户密码!");

 form.pwd.select();

 %如果密码为空,则将焦点定位在密码输入框

 return(false);

 %返回假

}

return(true);

%只有用户名和密码都不为空的情况下,才返回真

 }

</script>

<form name="form1" method="post" action="chkadmin.php" onSubmit="return chkinput(this)">

%如果用户点击提交按钮,那么页面将调用chkinput的JavaScript脚本来验证用户名和密码是否为空

%并将业务提交给chkadmin.php来处理

  <table width="547" border="0" align="center" cellpadding="0" cellspacing="0" id="__01">

<tr>

<td height="94" background="images/default_01.gif">&nbsp;</td>

</tr>

<tr>

<td height="160" align="center" background="images/default_02.gif"><table width="83%" height="93"  border="0" cellpadding="0" cellspacing="0">

          <tr>

            <td width="39%" height="30" align="right">管理员名称:&nbsp;</td>

            <td width="61%">&nbsp;              <input name="name" type="text" id="name"></td>

          </tr>

          <tr>

            <td height="30" align="right">管理员密码:&nbsp;</td>

            <td>&nbsp;            <input name="pwd" type="text" id="pwd"></td>

          </tr>

          <tr align="center">

            <td height="60" colspan="2"><input name="imageField" type="image" src="images/btn1.gif" width="79" height="37" class="input1">

            &nbsp;&nbsp;&nbsp;

            <input name="imageField2" type="image" src="images/btn2.gif" width="79" height="37" onClick="form.reset();return false;" class="input1">

            </td>

          </tr>

        </table></td>

</tr>

<tr>

<td height="23"  background="images/default_04.gif"></td>

</tr>

</table>

</form>

</body>

</html>

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值