英文xp无法提交表单,为什么

poplau 2008-06-17 05:23:12
偶用的IIS6
使用的ASP

我这边使用的中文版的XP都可以提交表单

但是用户是用的英文版XP,可以正常浏览,但登录提交表单的时候却无法执行。

是什么原因呀

现在贴下代码

<!--#include file="../public/ConstValue.asp"-->
<!--#include file="../login/Check.asp"-->
<%
stat = -1
name = Request("textfield")
password = Request("textfield2")
usertype = Request("select")
error = ""
stat = Login(name,password,usertype)
if(name<>"") then
if(stat=1) then
response.Redirect("/cadmin/index.asp")
else
error="用户名密码错误"
end if
else
error=""
end if
%>
<!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>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title><%= GetTitle()%></title>
<link href="../css/Adminlogin.css" rel="stylesheet" type="text/css" />
</head>
<body scroll='no' style="background-color: #F6F6F6">
<div id="iddivlogin" style="width:580px; position:absolute; z-index:5;">
<form name="form1" id="form1" action="login.asp" method="post">
<table width="580" border="0" cellpadding="0" cellspacing="0">
<tr>
<td><img src="../images/login_img/01.gif" width="580" height="136" onmousedown="did('iddivlogin')" /></td>
</tr>
</table>
<table border="0" cellpadding="0" cellspacing="0" class="tbg">
<tr>
<td align="center" valign="top">
<table width="320" height="116" border="0" cellpadding="0" cellspacing="0">
<tr>
<td width="82" class="f14b">身份选择: </td>
<td height="29" colspan="2" align="left"><select name="select" id="idselect1">
<option value="5">超级管理员</option>
</select> </td>
</tr>
<tr>
<td class="f14b">用 户 名:</td>
<td width="174" height="29" align="left"><input id="idtext1" type="text" name="textfield" /></td>
<td width="65" align="left"><span id='idspan1' style="font-size:12px;color:#ff0000"><%if(stat=0) then response.Write(error) end if%></span></td>
</tr>
<tr>
<td class="f14b">密    码:</td>
<td height="29" colspan="2" align="left"><input id="idtext2" type="password" name="textfield2" onkeydown="idtext2keydown()" /></td>
</tr>
<tr>
<td height="29" align="center"> </td>
<td height="29" colspan="2" align="left"><table width="120" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="73" align="left"><a href="javascript:;" onclick="Login()"><img src="../images/login_img/03.gif" style="border:none;" width="38" height="28" /></a></td>
<td width="70" align="left"><a href="javascript:;" onclick="Reset()"><img src="../images/login_img/04.gif" style="border:none;" width="38" height="28" /></a></td>
</tr>
</table></td>
</tr>
</table>
</td>
</tr>
</table>
</form>
</div>
<div id='iddiv001'></div>
</body>
<script type="text/javascript">
var Login=function(){
document.getElementById("form1").submit();
}

var Reset=function(){
document.getElementById("idtext1").value="";
document.getElementById("idtext2").value="";
}
var idtext2keydown=function(){
if(event.keyCode==13){
Login();
}
}

function getBodyObj()
{
return (document.documentElement) ? document.documentElement : document.body;
}

function initxy(){
document.getElementById("iddivlogin").style.marginLeft = parseInt(getBodyObj().clientWidth/2-290)+"px";
document.getElementById("iddivlogin").style.marginTop = "100px";
}
initxy();
</script>
</html>
...全文
66 8 打赏 收藏 转发到动态 举报
写回复
用AI写文章
8 条回复
切换为时间正序
请发表友善的回复…
发表回复
poplau 2008-06-19
  • 打赏
  • 举报
回复
问题已经解决,因为用户使用了版本较低的浏览器,对于<a href="javascript:;" onclick="Login()"> 这种提交
需要添加上window.event.returnValue=false;
这样才行
fanshuyi 2008-06-18
  • 打赏
  • 举报
回复
改成UTF-8的 。。。。。。。。。
fanshuyi 2008-06-18
  • 打赏
  • 举报
回复
编码问题吧 你里面有中文
bieyinan 2008-06-18
  • 打赏
  • 举报
回复
看具体的浏览器是什么?IE?还有浏览器是不是禁用了JS功能
poplau 2008-06-18
  • 打赏
  • 举报
回复
应该没有
因为initxy(); 这个函数是执行了的
poplau 2008-06-18
  • 打赏
  • 举报
回复
看具体的浏览器是什么?IE?还有浏览器是不是禁用了JS功能
JS是可以使用的。

该英文的XP浏览网站网页和URL传参数均正常,就是无法提交表单
redcn2004 2008-06-17
  • 打赏
  • 举报
回复
是不是js代码出现乱码了?
poplau 2008-06-17
  • 打赏
  • 举报
回复
有没有人遇见过呀 有没有人遇见过呀 有没有人遇见过呀

28,390

社区成员

发帖
与我相关
我的任务
社区描述
ASP即Active Server Pages,是Microsoft公司开发的服务器端脚本环境。
社区管理员
  • ASP
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧