% public ProductList if request("order")="产品更新" then Session("ProductList")="" end if ProductList = Session("ProductList") Sub PutToShopBag(Prodid, ProductList) If Len(ProductList) = 0 Then ProductList = "'" & Trim(Prodid) & "'" ElseIf InStr( ProductList, Prodid ) <= 0 Then ProductList = ProductList&", '"&Trim(Prodid)&"'" End If End Sub %> <% Product_Id = Trim(Request("Product_Id")) if instr(Product_Id,",")>0 then idArr=Split(Product_Id, ",") for i = 0 to ubound(idArr) PutToShopBag idArr(I), ProductList next else PutToShopBag Product_Id, ProductList end if %> <% Session("ProductList") = ProductList '判断购物车是否为空 if Productlist<>"''" then sql="select * from Products where Product_Id in ("&ProductList&") order by Product_Id" Set rs_price = conn.Execute(sql) else response.redirect "error.asp?error=007" response.end end if %> <% title="在线产品咨询" SiteContent="" %>