破釜沉舟论坛 » WEB 开发 » ASP问题~~

2006-4-16 15:35 怪怪
ASP问题~~

  这是出的错误!!红色部分是出错的行数!是怎么回事啊???

Microsoft VBScript 编译器错误 错误 '800a03f6'

缺少 'End'

/iisHelp/common/500-100.asp,行242

Microsoft JET Database Engine 错误 '80040e07'

标准表达式中数据类型不匹配。

/ly.asp,行111


<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "[url]http://www.w3.org/TR/html4/loose.dtd[/url]">
<!--#include file="conn.asp"-->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>留言本</title>
<style type="text/css">
<!--
body {
   margin-top: 0px;
   margin-bottom: 0px;
}
-->
</style>
<link href="ly.css" rel="stylesheet" type="text/css">
<%
   set rs=server.CreateObject("adodb.recordset")    
   sql="select * from biao order by id desc"
   rs.open sql,conn,1,2
%>

</head>
<script>
function changeimg()
{
   var img = document.form1.photo.value;
   document.form1.imgs.src = "photo/"+img+".gif";
}
  </script>


<body>
<table width="600" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
   <td height="8"></td>
  </tr>
  <tr>
   <td><img src="imges/logo.png" width="600" height="180"></td>
  </tr>
</table>
<table width="600" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
   <td height="25" align="right" background="imges/bg.png"><a href="ly.asp">我想留言</a>|<a href="admin.asp">管理留言</a>    </td>
  </tr>
  <tr>
   <td valign="top" background="imges/bg.png"><p> </p>    
   <%if request.form.count=0 then%>    

     <form name="form1" method="post" action="">
       <table width="400" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#D7EE9F">
         <tr>
           <td colspan="2"> </td>
         </tr>
         <tr>
           <td width="50" height="20" align="right">昵称:</td>
           <td><input name="sname" type="text" id="sname" size="20"></td>
         </tr>
         <tr>
           <td width="50" align="right">头像:</td>
           <td valign="middle">        
                   <table width="300" border="0" cellspacing="0" cellpadding="0">
             <tr>
               <td><select name="photo" id="photo" onChange="changeimg()">
                 <option value="0" selected>头像</option>
                 <option value="01">女生头像1</option>
                 <option value="02">女生头像2</option>
                 <option value="03">女生头像3</option>
                 <option value="04">女生头像4</option>
                 <option value="05">男生头像1</option>
                 <option value="06">男生头像2</option>
                 <option value="07">男生头像3</option>
                 <option value="08">男生头像4</option>
               </select></td>
               <td><img src="photo/0.gif" name="imgs" width="60" height="60" id="photo"></td>
             </tr>
           </table></td>
         </tr>
         <tr>
           <td width="50" height="20" align="right">邮箱:</td>
           <td><input name="mail" type="text" id="mail" size="20"></td>
         </tr>
         <tr>
           <td width="50" height="20" align="right">QQ:</td>
           <td><input name="qq" type="text" id="qq" size="20"></td>
         </tr>
         <tr>
           <td width="50" height="20" align="right">主页:</td>
           <td><input name="homepage" type="text" id="homepage" value="http://"></td>
         </tr>
         <tr>
           <td align="right">留言内容:</td>
           <td><textarea name="ly" cols="30" rows="7" id="ly"></textarea></td>
         </tr>
         <tr>
           <td> </td>
           <td><input type="submit" name="Submit" value="提交">
           <input type="reset" name="Submit2" value="重置"></td>
         </tr>
       </table>
     </form>
     <%
    a = request("sname")
    b = request("photo")
    c = request("mail")
   d = request("qq")
    e= request("homepage")
    f = request("ly")
     g = request("hfly")
    sql = "insert into biao(sname,photo,mail,qq,homepage,ly,hfly) values('"&a&"','"&b&"','"&c&"','"&d&"','"&e&"','"&f&"','"&g&"')"
   [color=red]conn.execute sql[/color]
    response.Write "<script>alert('留言成功!');location='index.asp';</script>"
%>
     
      <%end if%>
     <table width="580" border="0" cellspacing="0" cellpadding="0">
       <tr>
         <td> </td>
       </tr>
     </table></td>
  </tr>
  <tr>
   <td><img src="imges/wei.png" width="599" height="15"></td>
  </tr>
</table>
<table width="580"  border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
   <td height="8"></td>
  </tr>
  <tr>
   <td align="center">怪怪设计 版权所有 © 2005-2006<BR>
设计制作:怪怪杰 QQ交流群:15801664</td>
  </tr>
  <tr>
   <td height="8"></td>
  </tr>
</table>

<table width="580" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
   <td> </td>
  </tr>
  <tr>
   <td></td>
  </tr>
</table>
</body>
</html>

2006-4-16 15:52 dyp0356
funcation应该有end funcation

2006-4-16 17:34 怪怪
不懂你讲的是什么意思。。可以再详细点吗?

2006-4-28 01:21 duma
你用的是什么数据库?

2006-4-28 01:25 祥子
参数的数据类型,与你数据库中的相应字段的数据类型不一致

2006-4-29 09:41 怪怪
哦。。那我好好看看啊!

页: [1]
查看完整版本: ASP问题~~


Powered by Discuz! Archiver 5.5.0  © 2001-2006 Comsenz Inc.