<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%><%option Explicit response.charset="utf-8" dim listnum,t,tlnum,totalPut, CurrentPage, TotalPages,filename,filen,thisn,totalnumber Dim ThisID,lmid,p_id,m_id,s_id,Order_ID,Order_Num,CurID CurID=0 ThisID=5 p_id=request("id") If p_id="" Or Not IsNumeric(p_id) Then p_id=0 m_id=request("mid") If m_id="" Or Not IsNumeric(m_id) Then m_id=0 s_id=request("sid") If s_id="" Or Not IsNumeric(s_id) Then s_id=0%> IC产品 ic商城 商品已成功加入购物车 - 北京中其伟业科技有限公司

我挑选的商品

<% Dim uId2 uId2=request.Cookies("zqUserOrder")("uId") If uId2="" Or not IsNumeric(uId2) Then uId2=0 conn.execute("delete from stock_order where ic8<'" & DateAdd("d",-1,Now()) & "' and userid<=0") If CHK_Login Then If uId2="" Or IsNumeric(uId2) Then uId2=0 If Int(uId2)<0 Then conn.execute("update stock_order set userid=" & uId & " where orderid=0 and userid=" & uId2) ElseIf Uid2<0 Then uId=uId2 Else randomize uId=int(300*rnd)+100 uId=-GetDate(now()) & uId Response.Cookies("zqUserOrder")("uId")=uId Response.Cookies("zqUserOrder").Expires=DateAdd("h",10,Now()) End If Function GetDate(showtime) Dim mo,da if IsDate(showtime) then mo=hour(showtime) da=minute(showtime) if int(mo)<10 then mo="0" & mo if int(da)<10 then da="0" & da GetDate=mo & da da=second(showtime) if int(da)<10 then da="0" & da GetDate=GetDate & da end if End Function If p_id>0 And Get_Top1("select id from ic_sell where id=" & p_id,1)>0 Then Call Insert_Stock_P(p_id) elseIf m_id>0 And Get_Top1("select model_id from model where model_id=" & m_id,2)>0 Then Call Insert_Stock_M(m_id) elseIf s_id>0 And Get_Top1("select sHeadid from stock where sHeadid=" & s_id,2)>0 Then Call Insert_Stock_S(s_id) End If 'If p_id>0 And Get_Top1("select id from ic_sell where id=" & p_id,1)>0 Then ' Call SetCookie("P" & p_id ,1) 'elseIf m_id>0 And Get_Top1("select model_id from model where model_id=" & m_id,2)>0 Then ' Call SetCookie("M" & m_id,1) 'elseIf s_id>0 And Get_Top1("select sHeadid from stock where sHeadid=" & s_id,2)>0 Then ' Call SetCookie("S" & s_id,1) 'End If ' 'Dim Order_ID_T,Order_ID_NID 'For i=1 To Order_Num ' Order_ID_T=request.Cookies("zqUserOrder")("ID_" & i) ' If Order_ID_T<>"" Then ' Order_ID_NID=Right(Order_ID_T,Len(Order_ID_T)-1) ' Order_ID_T=Left(Order_ID_T,1) ' If Order_ID_T="P" then' id_sell ' Call Show_Stock_P(Order_ID_NID) ' ElseIf Order_ID_T="M" then' model ' Call Show_Stock_M(Order_ID_NID) ' ElseIf Order_ID_T="S" then' stock ' Call Show_Stock_S(Order_ID_NID) ' End if ' End if 'next set rs=server.CreateObject("adodb.recordset") sql="select * from stock_order where userid=" & uId & " and orderid=0 order by id" rs.open sql,conn,1,1 do while not rs.eof response.write("") response.write("") response.write(" ") response.write(" ") response.write(" ") response.write(" ") If rs("ic5")=0 Then response.write(" ") Else response.write(" ") End if response.write(" ") response.write(" ") response.write("") rs.movenext loop rs.close set rs=nothing %>
选择 型号 产品描述 库存状况 包装规格 单位价格
(不含税)
数量 操作
" & rs("ic1") & " " & rs("ic2") & "" & rs("ic3") & "" & rs("ic4") & "面议" & rs("ic5") & "删除
<% Function Insert_Stock_P(id) 'id_sell Dim rs,IMG set rs=server.CreateObject("adodb.recordset") sql="select * from ic_sell where id=" & id rs.open sql,conn,1,1 If rs.eof Then Exit Function IMG=rs("rs2") If IMG="" Then IMG="/nopic.jpg" Call ShowTable("P" , rs("id"),IMG,"" & rs("rs1") & "",rs("memo"),Replace(rs("rs7"),",","
"),rs("rs8"),rs("rs9")) rs.close set rs=Nothing End Function Function Insert_Stock_M(id) 'model Dim rs set rs=server.CreateObject("adodb.recordset") sql="select * from model where model_id=" & id rs.open sql,conn2,1,1 If rs.eof Then Exit Function Call ShowTable("M" , rs("model_id"),"/nopic.jpg",Trim(rs("model_name")),"原装","现货"," "," ") rs.close set rs=Nothing End Function Function Insert_Stock_S(id) 'stock Dim rs set rs=server.CreateObject("adodb.recordset") sql="select sCJName,sfz,sPH,sPrice,sHeadid,sBName from stock where sHeadid=" & id rs.open sql,conn2,1,1 If rs.eof Then Exit Function Call ShowTable("S" , rs("sHeadid"),"/nopic.jpg",Trim(rs("sBName")),"原装现货" &rs(0),"现货","封装:" &rs(1) & " 批号:" &rs(2),rs(3)) rs.close set rs=Nothing End Function Function ShowTable(pTID,pid,IMG,V1,V2,V3,V4,V5) If Get_Top1("select id from Stock_Order where orderid=0 and userid=" & uId & " and pTID='" & pTID & "' and pID=" & pid,1)=0 Then If V5="" Or Not IsNumeric(V5) Then V5=0 conn.execute("insert into Stock_Order (userid,pID,pTID,img,ic1,ic2,ic3,ic4,ic5,ic6) values (" & uId & "," & pid & ",'" & pTID & "','" & IMG & "','" & Func_QK(V1) & "','" & Func_QK(V2) & "','" & Func_QK(V3) & "','" & Func_QK(V4) & "','" & V5 & "',1)") End if End Function Function Func_QK(V) Dim L1,L2 If V<>"" Then V=Replace(V,"
  • "," ") L1=InStr(1,V,"<") Do While L1>0 L2=InStr(L1,V,">")+1 If L2=1 Then Exit Do V=replace(V,Mid(V,L1,L2-L1),"") L1=InStr(1,V,"<") Loop V=Replace(V,"'","''") End if Func_QK=V End Function ' response.write("") ' response.write("") ' response.write(" " & V1 & " ") ' response.write(" " & V2 & "") ' response.write(" " & V3 & "") ' response.write(" " & V4 & "") ' response.write(" " & V5 & "") ' response.write(" ") ' response.write(" 删除") ' response.write("") 'Function SetCookie(id,id_n) ' Dim isAdd ' If Order_Num=0 Then ' Response.Cookies("zqUserOrder")("ID_1")=id ' Response.Cookies("zqUserOrder")("ID_Num")=1 ' Order_Num=1 ' Else ' isAdd=false ' For i=1 To Order_Num ' If request.Cookies("zqUserOrder")("ID_" & i)=id then ' isAdd=True ' Exit for ' End if ' Next ' If Not isAdd Then ' Response.Cookies("zqUserOrder")("ID_" & i)=id ' Response.Cookies("zqUserOrder")("ID_Num")=i ' Order_Num=i ' End if ' End If ' Response.Cookies("zqUserOrder").Expires=DateAdd("h",4,Now()) 'End Function %>