<% Cate=Replace(Trim(Request("uLX")),"'","") if Request("uLX")="" and Request("LX")<>"" then Cate=Replace(Trim(Request("LX")),"'","") anclassid=Replace(Trim(Request("anid")),"'","") nclassid=Replace(Trim(Request("nid")),"'","") page=request("page") if page>1 then tpage="第"&page&"页-" else tpage="" if nclassid<>"" or anclassid<>"" then if anclassid<>"" then sql="select anclass from shop_anclass where anclassid="&anclassid if nclassid<>"" and anclassid<>"" then sql="select anclass,nclass from shop_anclass a,shop_nclass b where a.anclassid="&anclassid&" and nclassid="&nclassid Set Rs=Server.CreateObject("adodb.recordset") rs.open sql,conn,1,1 if not rs.eof then if nclassid<>"" then nclass=rs("nclass")&"价格-"&rs("nclass")&"报价-" if anclassid<>"" and nclassid<>"" then anclass=rs("anclass")&"-" if anclassid<>"" and nclassid="" then anclass=rs("anclass")&"价格-"&rs("anclass")&"报价-" else nclass="小类" anclass="大类" end if rs.close Set Rs=Nothing else Select Case Cate Case "Big" nclass= "大类商品-" Case "Small" nclass= "小类商品-" Case "Tejia" nclass= "特价商品-" Case "New" nclass= "新品上架-" Case else nclass= "新品上架-" End Select end if %> <%=nclass%><%=anclass%><%=tpage%><%=WebName%> <% 'Response.Write (Cate&"--"&anclassid&"--"&nclassid) 'Response.End() %>
电气报价网:如找不到想要的产品,请加在线QQ:1103401247 或手机联系:13367335706
<% Set Rs=Server.CreateObject("adodb.recordset") Rs.Open "Select * from shop_anclass order by anclassidorder",conn,1,1 %>
<% Select Case Cate Case "Big" Response.Write "大类商品" Case "Small" Response.Write "小类商品" Case "Tejia" response.Write "特价商品" Case "New" Response.Write "新品上架" Case else Response.Write "新品上架" End Select %>
 
<% Set Rs=Server.Createobject("adodb.recordset") Select Case Cate Case "Big" Rs.Open "select * from shop_books where anclassid="&anclassid&" order by adddate desc",Conn,1,1 Case "Small" Rs.Open "Select * from shop_books where anclassid="&anclassid&" and nclassid="&nclassid&" order by adddate desc",Conn,1,1 Case "Tejia" Rs.Open "select * from shop_books where tejiabook=1 order by adddate desc",Conn,1,1 Case "New" Rs.Open "select * from shop_books where newsbook=1 order by adddate desc",Conn,1,1 Case Else Rs.Open "Select * from shop_books where newsbook=1 order by adddate desc",Conn,1,1 End Select If Rs.Recordcount=0 Then %>
暂无商品
<% else rs.PageSize =15 '每页记录条数 iCount=rs.RecordCount '记录总数 iPageSize=rs.PageSize maxpage=rs.PageCount if Not IsNumeric(page) or page="" then page=1 else page=cint(page) end if if page<1 then page=1 elseif page>maxpage then page=maxpage end if rs.AbsolutePage=Page if page=maxpage then x=iCount-(maxpage-1)*iPageSize else x=iPageSize end if For i=1 To x %> <% rs.movenext next call PageControl(iCount,maxpage,page,"border=0 align=center","

") end if rs.close set rs=nothing Sub PageControl(iCount,pagecount,page,table_style,font_style) '生成上一页下一页链接 Dim query, a, x, temp action = "http://" & Request.ServerVariables("HTTP_HOST") & Request.ServerVariables("SCRIPT_NAME") query = Split(Request.ServerVariables("QUERY_STRING"), "&") For Each x In query a = Split(x, "=") If StrComp(a(0), "page", vbTextCompare) <> 0 Then temp = temp & a(0) & "=" & a(1) & "&" End If Next Response.Write("" & vbCrLf ) Response.Write("" & vbCrLf ) Response.Write("" & vbCrLf ) Response.Write("" & vbCrLf ) Response.Write("
" & vbCrLf ) Response.Write(font_style & vbCrLf ) if page<=1 then Response.Write ("首页 " & vbCrLf) Response.Write ("上页 " & vbCrLf) else Response.Write("首页 " & vbCrLf) Response.Write("上页 " & vbCrLf) end if if page>=pagecount then Response.Write ("下页 " & vbCrLf) Response.Write ("尾页 " & vbCrLf) else Response.Write("下页 " & vbCrLf) Response.Write("尾页 " & vbCrLf) end if Response.Write(" 页次:" & page & "/" & pageCount & "页" & vbCrLf) Response.Write(" 共有" & iCount & "种商品" & vbCrLf) Response.Write(" 转到" & "" & "页" & vbCrLf & "") Response.Write("
" & vbCrLf ) End Sub %>

<% CloseConn() %>