<% main() Sub main() If Not(InternetCheck()) Then Exit Sub End If If Not(VisitorCheck()) Then Exit Sub End If 'Response.Write(GB_VisitorID) 'Exit Sub %> <% Dim TmpShop Dim Gokei Dim Query Dim Content Dim Content2 %>
買い物かごに入っている商品
<% 'ショップ配列を作る Dim ShopAry ReDim ShopAry(0) If SelShop <> "" Then '単一ショップ表示の場合 ReDim PreServe ShopAry(UBound(ShopAry) + 1) '配列+1 ShopAry(UBound(ShopAry)) = SelShop Else TmpShop = "" Query = "exec SPF買い物かご取得 '" & VisitorYMDGet(GB_VisitorID) & "', " & VisitorIDGet(GB_VisitorID) & ", null" Set Content = SQLQuery(Query, SQLServer, DatabaseName, DatabaseUser, DatabasePass) Do While Not(Content.BOF Or Content.EOF) 'ローカルモードは演習CDで絞込み If LocalMode <> "1" Or GB_PracticeCD = "" & Content.Fields("演習CD") Then If Content.Fields("ショップID") <> TmpShop Then 'ショップログインID引数による強制表示 If "" & Content.Fields("ショップ公開フラグ") = "1" Or (Session("ECMallShopVisible") <> "" And LCase(Left("" & Content.Fields("ログインID"), Len(Session("ECMallShopVisible")))) = LCase(Session("ECMallShopVisible"))) Then TmpShop = Content.Fields("ショップID") ReDim PreServe ShopAry(UBound(ShopAry) + 1) '配列+1 ShopAry(UBound(ShopAry)) = Content.Fields("ショップID") End If End If End If Content.MoveNext Loop End If 'Response.Write(UBound(ShopAry)) 'Exit Sub Dim SCnt For SCnt = 1 To UBound(ShopAry) %> <% If SelShop = "" Then %> <% End If %> <% Gokei = 0 Query = "exec SPF買い物かご取得 '" & VisitorYMDGet(GB_VisitorID) & "', " & VisitorIDGet(GB_VisitorID) & ", " & ShopAry(SCnt) & "" Set Content = SQLQuery(Query, SQLServer, DatabaseName, DatabaseUser, DatabasePass) If Content.BOF Or Content.EOF Then %> <% ' Response.Redirect("" & HomeAliasSL & "shop.asp?SelShop=" & ShopAry(SCnt) & "") '0件になったら戻る Else Do While Not(Content.BOF Or Content.EOF) %> <% Gokei = Gokei + Content.Fields("価格") * Content.Fields("数量") Content.MoveNext Loop ' If Gokei > 0 Then %> <% ' End If End If %>
<% Set Content = QueryGetShop(ShopAry(SCnt), SQLServer, DatabaseName, DatabaseUser, DatabasePass) If Not(Content.BOF Or Content.EOF) Then %> <% = Content.Fields("名称") %> <% End If %>
商品がありません
&Item=<% = Content.Fields("商品ID") %>"><% = Content.Fields("名称") %> <% If Content.Fields("価格") = 0 Then %> 時価 <% Else %> ¥<% = ConvIntToMoney(Content.Fields("価格"), False, False) %>(<% If "" & Content.Fields("消費税フラグ") = "1" Then %>税込<% Else %>税別<% End If %>) <% End If %>
数量 <% = Spacer(3, 1) %> I<% = Content.Fields("商品ID") %>" value="<% = Content.Fields("数量") %>" class="tb1416r" style="width:40px;" maxlength="3" onKeyup="this.value=this.value.replace(/[^0-9]+/,'');" onBlur="this.value=this.value.replace(/[^0-9]+/,'');"> <% = Spacer(3, 1) %> <% = ActionButton3Image("QtyBtn" & Content.Fields("ショップID") & "_" & Content.Fields("商品ID"), "images/btn01bl.png", "images/btn01bl_o.png", 4, "images/btn01bc.png", "images/btn01bc_o.png", 32, "images/btn01br.png", "images/btn01br_o.png", 4, 24, "変更", "tx1416w", "center", "location.href='" & HomeAliasSL & "cart_bin.asp?SelShop=" & SelShop & "&Shop=" & Content.Fields("ショップID") & "&Item=" & Content.Fields("商品ID") & "&Qty='+form1.QtyS" & Content.Fields("ショップID") & "I" & Content.Fields("商品ID") & ".value+'&Mode=Change';") %>
小計 ¥<% = ConvIntToMoney(Content.Fields("価格") * Content.Fields("数量"), False, False) %> <% = ActionButton3Image("DeleteBtn" & Content.Fields("ショップID") & "_" & Content.Fields("商品ID"), "images/btn01bl.png", "images/btn01bl_o.png", 4, "images/btn01bc.png", "images/btn01bc_o.png", 32, "images/btn01br.png", "images/btn01br_o.png", 4, 24, "削除", "tx1416w", "center", "if(confirm('" & Content.Fields("名称") & " を\n買い物かごから削除してよろしいですか? ')){location.href='" & HomeAliasSL & "cart_bin.asp?SelShop=" & SelShop & "&Shop=" & Content.Fields("ショップID") & "&Item=" & Content.Fields("商品ID") & "&Mode=Delete';}") %>
<% = ActionButton3Image("ReturnShopBtn" & ShopAry(SCnt), "images/btn01bl.png", "images/btn01bl_o.png", 4, "images/btn01bc.png", "images/btn01bc_o.png", 102, "images/btn01br.png", "images/btn01br_o.png", 4, 24, "ショップに戻る", "tx1416w", "center", "location.href='" & HomeAliasSL & "shop.asp?SelShop=" & ShopAry(SCnt) & "';") %> <% = ActionButton3Image("OrderBtn" & ShopAry(SCnt), "images/btn01bl.png", "images/btn01bl_o.png", 4, "images/btn01bc.png", "images/btn01bc_o.png", 102, "images/btn01br.png", "images/btn01br_o.png", 4, 24, "注文手続に進む", "tx1416w", "center", "location.href='" & HomeAliasSL & "login.asp?SelShop=" & ShopAry(SCnt) & "';") %> 合計 ¥<% = ConvIntToMoney(Gokei, False, False) %> <% = ActionButton3Image("AllDeleteBtn" & ShopAry(SCnt), "images/btn01bl.png", "images/btn01bl_o.png", 4, "images/btn01bc.png", "images/btn01bc_o.png", 46, "images/btn01br.png", "images/btn01br_o.png", 4, 24, "全削除", "tx1416w", "center", "if(confirm('買い物かごの商品を全て削除してよろしいですか? ')){location.href='" & HomeAliasSL & "cart_bin.asp?SelShop=" & SelShop & "&Shop=" & ShopAry(SCnt) & "&Mode=Clear';}") %>

<% Next %> <% = ActionButton3Image("HistoryBtn", "images/btn01bl.png", "images/btn01bl_o.png", 4, "images/btn01bc.png", "images/btn01bc_o.png", 62, "images/btn01br.png", "images/btn01br_o.png", 4, 24, "注文履歴", "tx1416w", "center", "location.href='" & HomeAliasSL & "history.asp?SelShop=" & SelShop & "';") %>
<% End Sub %>