⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 shopping.asp

📁 网上商城~~ 手机类型的网站源码Asp
💻 ASP
字号:
<!--#include file="conn.asp" -->
<%
'当点击订购时调用该页面并传递商品编号
productid=Trim(request("id"))
if productid="" then
   response.write "<script>alert('暂无此商品信息,按任意键返回!');</script>"
   response.write "<script>this.location.href='products.asp';</script>"
   response.end
end if

if session("userid")="" then
	response.redirect "login_shop_window.asp?productid="&productid
else

//往临时订单库中添加订单

sql="select * from Net008_orderlist_temp where userid='"&session("userid")&"' and productid='"&productid&"'"
set rs=server.createobject("adodb.recordset")
rs.open sql,conn,1,2

if  rs.recordcount<1 then
	rs.addnew
	rs("userid")=session("userid")
	rs("productid")=productid
	rs("buynumber")=1
	rs("submitflag")=1
	rs("adddate")=now()
	rs.update
	rs.close
	set rs=nothing
else
	rs("buynumber")=rs("buynumber")+1
	rs.update
	rs.close
	set rs=nothing
end if
	response.redirect "shopping_list.asp"
end if
%>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -