<% Server.Execute "/NoHACK1.asp" dim Time1, sql, rs, Errh, LoopFlag, outTmp, picTmp, outTmp1, urlTmp, urlTmp1 dim GID, rs1, G_Type GID = ReqNum(Request("ID")) sql = "select * from ML_Goods where G_Show='Y' and AutoID=" & GID set rs1 = GetRecordset(sql) if rs1.BOF and rs1.EOF then response.Redirect "/main.asp" response.End end if '----加人氣 sql = "Update ML_Goods set G_Vote=G_Vote+1 where AutoID=" & GID Errh = DoCommand(sql) '----找出大分類 sql = "select T_Name from ML_Class where AutoID = (select TID from ML_Class2 where AutoID=" & CStr(rs1("G_Type")) & ")" set rs = GetRecordset(sql) G_Type = rs("T_Name") rs.close : set rs = nothing '----找出小分類 sql = "select T_Name from ML_Class2 where AutoID=" & CStr(rs1("G_Type")) set rs = GetRecordset(sql) G_Type = G_Type & " – " & rs("T_Name") rs.close : set rs = nothing %> 完美商城乾坤袋
         
<% dim RecCount, BannerID(5), BannerPic(5), BannerUrl(5), Idx sql = "Select AutoID,PicName,Url from TOP_Banner Where ShowMall='Y' And BannerType='A' And " & _ "DateDiff(d, StartDay, GetDate())>=0 And DateDiff(d, EndDay, GetDate())<=0 Order By AddTime desc, AutoID desc" Set rs = GetRecordset( sql ) if rs.BOF and rs.EOF then RecCount = 0 else RecCount = rs.RecordCount end if ' 若資料小於五筆 直接全列出 if RecCount < 6 then For LoopFlag = 1 to 5 if rs.EOF then BannerID(LoopFlag) = "" BannerPic(LoopFlag) = "" BannerUrl(LoopFlag) = "" else BannerID(LoopFlag) = CStr(rs(0).value) BannerPic(LoopFlag) = rs(1).value BannerUrl(LoopFlag) = Trim(rs(2).value) rs.movenext end if Next else ' 隨機取資料 Randomize ' 取亂數將隨機五筆存入Array For LoopFlag = 1 to 5 rs.AbsolutePosition = Int((RecCount * Rnd) + 1) BannerID(LoopFlag) = CStr(rs(0).value) BannerPic(LoopFlag) = rs(1).value BannerUrl(LoopFlag) = Trim(rs(2).value) ' 過濾重覆的 For Idx = 1 to LoopFlag - 1 if BannerID(LoopFlag) = BannerID(Idx) then LoopFlag = LoopFlag - 1 exit For end if Next Next end if rs.close set rs = nothing %>
 
<%if rs1("G_Tenantry")="A" then%> <%end if%> <%if rs1("G_Tenantry")="A" then%> <%end if%> <%if rs1("G_Tenantry")="A" then%> <%end if%>
<%=G_Type%>
" width="75" height="75">
名稱
<%=rs1("G_Name")%>
商品類型
<%if rs1("G_Hot")="Y" then%>   <%end if select case rs1("G_Kind") case "A" response.Write "發燒新貨" case "B" response.Write "熱門商品" case "C" response.Write "特價商品" case "D" response.Write "一般商品" case else response.Write "一般商品" end select %>
上架時間
<%=FormatDateTime(rs1("AddTime"),vbShortDate)%>
使用等級限制
 <%=rs1("G_Lv")%>

職業或
性別限定

 <%=rs1("G_Limit")%>
數量
 <%=rs1("G_Num")%>
是否綁定
 <%=rs1("G_Bind")%>
 
 

使用期限

"A" then%> colspan="3"<%end if%>>
 <%=rs1("G_Tenant1")%>
 <%=rs1("G_Tenant2")%>
 <%=rs1("G_Tenant3")%>
原價
"A" then%> colspan="3"<%end if%>>
<%if Trim(rs1("G_Price1s"))<>"" then%><%end if%> <%=rs1("G_Price1")%><%if Trim(rs1("G_Price1s"))<>"" then%><%end if%>
<%if Trim(rs1("G_Price2s"))<>"" then%><%end if%> <%=rs1("G_Price2")%><%if Trim(rs1("G_Price2s"))<>"" then%><%end if%>
<%if Trim(rs1("G_Price3s"))<>"" then%><%end if%> <%=rs1("G_Price3")%><%if Trim(rs1("G_Price3s"))<>"" then%><%end if%>
特價
"A" then%> colspan="3"<%end if%>>
 <%=rs1("G_Price1s")%>
 <%=rs1("G_Price2s")%>
 <%=rs1("G_Price3s")%>

商品說明

<%=rs1("G_Data")%>
現正熱賣

 

<% rs1.close : set rs1 = nothing %>