急啊?不知道那里出错了????
数据库绝对没有问题
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!--#include file="conn.asp"-->
<!--#include file="util.asp"-->
<%
if request("submit")="我要结帐" then
if session("usr")="" then
response.Redirect("enter/enter.asp")
end if
ProductList=session("Productlist")
usr=session("usr")
pwd=session("pwd")
Products=split(ProductList,",")
for i=0 to UBound(Products)
sql="insert into goods_buyed(帐号,商品,数量,IP)values('"
sql=sql&usr&"',"
sql=sql&Products(i)&","
sql=sql&request("Q_"&replace(Products(i),"'",""))&",'"
sql=sql&request("remote_addr")&"')"
con.execute sql
next
%>
<script language="JavaScript">
window.alert("您已经完成了购物的过程,谢谢您的支持");
window.location.href="enter/abandon.asp"
</script>
<%
response.End()
end if
%>
<%
Head="以下是您购物的清单"
ProductList=session("ProductList")
if len(ProductList)=0 then
response.Redirect("nothing.asp")
end if
if request("MySelf")="Yes" then
ProductList=""
Products=split(Request("ProductID"),",")
for I=0 to UBound(Products)
PutToShopBag Products(I),ProductList
next
session("ProductList")=ProductList
end if
sql="select * from Products"
sql=sql&"Where ProductID In("&ProductList&")"
sql=sql&"Order By ProductID"
set rs=conn.execute(sql)
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title><%=Head%></title>
</head>
<body>
<h2 align="center"><%=Head%></h2><hr>
<center>
<form action="check.asp" method="post">
<input type="hidden" name="MySelf" value="Yes">
<table border="1">
<tr>
<td>取消</td>
<td>商品编号</td>
<td>商品名称</td>
<td>单价</td>
<td>数量</td>
<td>总价</td>
<td>商品简介</td>
</tr>
<%
Sum=0
while not rs.eof
Quatity=Cint(Request("Q_"&rs("ProductID")))
if Quatity <= 0 then
Quatity=cint(session(rs("ProductID")))
if Quatity <=0 then
Quatity=1
end if
end if
session(rs("ProductID"))=Quatity
Sum=Sum+CDbl(rs("Price"))*Quatity
%>
<tr>
<td><input type="checkbox" name="ProductID" value="<%=rs("ProductID")%>" checked></td>
<td><%=rs("ProductID")%></td>
<td><%=rs("ProductName")%></td>
<td><%=rs("Price")%></td>
<td><input type="text" name="<%="Q_"&rs("ProductID")%>" value="<%=Quatity%>" size="3"></td>
<td><%=CDbl(rs("Price"))*Quatity%></td>
<td><%=rs("Description")%></td>
</tr>
<%
rs.movenext
wend
%>
<tr>
<td colspan="7">总价格:<%=Sum%></td>
</tr>
</table>
<input type="submit" value="我要结帐">
<input type="submit" value="更改数量">
</form>
<hr>
<a href="clear.asp">退回所有商品</a><p>
<%ListCategory conn%>
</center>
</body>
</html>
出现的错误是:
Microsoft VBScript 编译器错误 错误 '800a03f6'
缺少 'End'
/iisHelp/common/500-100.asp,行242
Microsoft OLE DB Provider for ODBC Drivers 错误 '80040e14'
[Microsoft][ODBC SQL Server Driver][SQL Server]在关键字 'In' 附近有语法错误。
/shop/check.asp,行48
是怎么回事啊?