日期:2014-05-17  浏览次数:20815 次

我的这个代码怎么改正
<%@LANGUAGE= "VBSCRIPT "   CODEPAGE= "936 "%>
<html>
<head>
<title> 学生管理员登录界面 </title>
<style   type= "text/css ">
<!--
.style6   {font-size:   16px}
-->
</style>
</head>
<body   bgcolor=pink>
<h2   align=center>   学   生   管   理   系   统 </h2>
<p   align=center> &nbsp; </p>
<form   method=post   name=danglu   action= "guanli.asp ">
<table   width= "944 "   height= "394 "   border= "0 ">
    <tr>
        <td   width= "234 "   rowspan= "4 "> <img   src= "2e_top.jpg "   width= "188 "   height= "392 "> </td>
        <td   height= "53 "   colspan= "2 "> &nbsp; </td>
        <td   width= "173 "   rowspan= "4 "> <img   src= "2e_right.jpg "   width= "180 "   height= "386 "> </td>
    </tr>
    <tr>
        <td   width= "160 "   height= "97 "> <span   class= "style6 "> 请输入你的账户: </span> </td>
        <td   width= "331 "> <input   type= "text "   name= "zhanghu "   size= "20 "> </td>
    </tr>
    <tr>
        <td   height= "79 "> <span   class= "style6 ">   请输入你的密码:   </span> </td>
        <td   width= "331 "> <input   type= "text "   name= "mima "   size= "20 "> </td>

        <td   width= "12 "> &nbsp; </td>
    </tr>
    <tr>
        <td   height= "153 "> <input   name= "submit "   type=submit   value= "确定 "> </td>
        <td> <input   type=reset   value= "重填 "> </td>
    </tr>
</table>
<tr> <td> &nbsp; </td>

</body>
</html>

guanli.asp的代码
<%
strUserName=request.Form( "zhanghu ")
strUserPassword=request.Form( "mima ")
if   sreUserName= "admin "   and   strUserPassword= "123456 "   then
response.redirect   "guanli1.asp "

else
response.write   "你有要求不符合 "
end   if
%>
为什么第二个文件代码永远不执行前面的if语句,而永远都执行后面的else语句,怎么改正,真是晕

------解决方案--------------------
guanli.asp里把strUserName写错成为sreUserName了
if strUserName= "admin " and strUserPassword= "123456 " then
------解决方案--------------------
<html>
<head>
<title> 学生管理员登录界面 </title>
<style type= "text/css ">
<!--
.style6 {font-size: