jscript 和 VBSCRIPT函数类型不匹配问题,请大家帮忙
源代码如下:
<!-- #include file="db.inc" -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title>New Page 1</title>
</head>
<script language="jscript">
<!--
function len_check(lenschool,lenplace){
if(lenschool>20)
{
window.alert("学校名称太长");
return (false);
}
if(lenplace>20)
{
window.alert("请简短填写队内职务");
return (false);
}
return(true);
}
-->
</script>
<body>
<%
dim strname,strschool,strplace
dim strphoto,boolPassed
dim lenschool,lenplace
strname=Session("I D")
'Response.write(strname)
boolPassed=Session("firstPassed")
'Response.write(boolPassed)
if(Not boolPassed) Then
Response.Redirect "LoginFail.asp"
else
strschool=Request("schoolname")
strplace=Request("place")
'获取长度
lenschool=len(strschool)
lenplace=len(strplace)
if (len_check(lenschool,lenplace)) then
mysql="insert into t_apply(username,schoolname,place)values('"&strname&"','"&strschool&"','"&strplace&"')"
conn.Execute(mysql)
end if
end if
%>
</body>
</html>
执行的时候总是提示如下:
Microsoft VBScript 编译器错误 错误 '800a03f6'
缺少 'End'
/iisHelp/common/500-100.asp,行242
Microsoft VBScript 运行时错误 错误 '800a000d'
类型不匹配: 'len_check'
/addapply.asp,行110
大家帮我看一下问题处在什么地方
非常感谢