<% call SiteInfo if ISHTML = 1 then Response.expires = 0 Response.expiresabsolute = Now() - 1 Response.addHeader "pragma", "no-cache" Response.addHeader "cache-control", "private" Response.CacheControl = "no-cache" End If if request.QueryString("SortID")="" then SeoTitle="公司产品" elseif not IsNumeric(request.QueryString("SortID")) then SeoTitle="参数错误" elseif conn.execute("select * from test_ProductSort Where ViewFlag"&Language&" and ID="&request.QueryString("SortID")).eof then SeoTitle="参数错误" else set rs = server.createobject("adodb.recordset") sql="select * from test_ProductSort where ViewFlag"&Language&" and ID="&request.QueryString("SortID") rs.open sql,conn,1,1 SeoTitle=rs("SortName"&Language) rs.close set rs=nothing end if %> <% =SeoTitle %> - <% =SiteTitle %>
<% '调用显示节点------------------------------ Function CallFolderView() %> <% Folder(0) %> <% End Function '列出所有节点------------------------------ Function Folder(id) Dim rs,sql,i,ChildCount,FolderType,FolderName,onMouseUp,ListType,ViewFlag Set rs=server.CreateObject("adodb.recordset") sql="Select * From test_ProductSort where ViewFlag"&Language&" and ParentID="&id&" order by id" rs.open sql,conn,1,1 if id=0 and rs.recordcount=0 then response.write ("No Information!") response.end end if i=1 response.write("") while not rs.eof ChildCount=conn.execute("select count(*) from test_ProductSort where ParentID="&rs("id"))(0) if ChildCount=0 then if i=rs.recordcount then FolderType="SortFileEnd" else FolderType="SortFile" end if FolderName=rs("SortNameCh")&" "&ViewFlag onMouseUp="" else if i=rs.recordcount then FolderType="SortEndFolderOpen" ListType="SortEndListline" onMouseUp="EndSortChange('a"&rs("id")&"','b"&rs("id")&"');" else FolderType="SortFolderOpen" ListType="SortListline" onMouseUp="SortChange('a"&rs("id")&"','b"&rs("id")&"');" end if FolderName=rs("SortNameCh")&" "&ViewFlag end if If ISHTML = 1 Then AutoLink = ""&ProSortName&""&Separated&""&rs("ID")&""&Separated&"1."&HTMLName&"" Else AutoLink = "ProductList.asp?SortID="&rs("ID")&"" End If response.write("") response.write("") if ChildCount>0 then %> " style="display:none"> <% end if rs.movenext i=i+1 wend response.write("
"&FolderName&"        ") response.write("
<% Folder(rs("id")) %>
") rs.close set rs=nothing end function function WebLocation() WebLocation=" 当前位置:首页 - 公司产品"&VbCrLf if request.QueryString("SortID")="" then WebLocation=WebLocation elseif not IsNumeric(request.QueryString("SortID")) then WebLocation=WebLocation&"参数错误" elseif conn.execute("select * from test_ProductSort Where ViewFlag"&Language&" and ID="&request.QueryString("SortID")).eof then WebLocation=WebLocation&"参数错误" else dim rs,sql set rs = server.createobject("adodb.recordset") sql="select * from test_ProductSort where ViewFlag"&Language&" and ID="&request.QueryString("SortID") rs.open sql,conn,1,1 WebLocation=WebLocation&SortPathTXT("test_ProductSort",rs("ID")) rs.close set rs=nothing end if end Function function SortPathTXT(DataFrom,ID) dim rs,sql Set rs=server.CreateObject("adodb.recordset") sql="Select * From "&DataFrom&" where ViewFlag"&Language&" and ID="&ID rs.open sql,conn,1,1 if not rs.eof Then If ISHTML = 1 Then AutoLink = ""&ProSortName&""&Separated&""&rs("ID")&""&Separated&"1."&HTMLName&"" Else AutoLink = "Productlist.asp?Sortid="&rs("ID")&"" End If SortPathTXT=SortPathTXT(DataFrom,rs("ParentID"))&" - "&rs("SortName"&Language)&"" end if rs.close set rs=nothing end function function WebContent(DataFrom,ID,SortPath) dim rs,sql dim HideSort set rs = server.createobject("adodb.recordset") if ID="" then SortPath="0," elseif not IsNumeric(ID) then response.write "
暂无相关信息
" exit function elseif conn.execute("select * from "&DataFrom&" Where ViewFlag"&Language&" and ID="&ID).eof then response.write "
暂无相关信息
" exit function else SortPath=conn.execute("select * from "&DataFrom&" Where ViewFlag"&Language&" and ID="&ID)("SortPath") conn.execute("update "&DataFrom&" set ClickNumber=ClickNumber+1 Where ID="&ID) end if sql="select * from "&DataFrom&" Where not(ViewFlag"&Language&") and Instr(SortPath,'"&SortPath&"')>0" rs.open sql,conn,1,1 while not rs.eof HideSort="and not(Instr(SortPath,'"&rs("SortPath")&"')>0) "&HideSort rs.movenext wend rs.close dim idCount dim pages pages=ProInfo dim pagec dim page page=clng(request("Page")) dim pagenc pagenc=5 dim pagenmax dim pagenmin dim pageprevious dim pagenext datafrom="test_Products" dim datawhere datawhere="where ViewFlag"&Language&" and Instr(SortPath,'"&SortPath&"')>0 "&HideSort& " " dim sqlid dim Myself,PATH_INFO,QUERY_STRING PATH_INFO = request.servervariables("PATH_INFO") QUERY_STRING = request.ServerVariables("QUERY_STRING")' if QUERY_STRING = "" then Myself = PATH_INFO & "?" elseif Instr(PATH_INFO & "?" & QUERY_STRING,"Page=")=0 then Myself= PATH_INFO & "?" & QUERY_STRING & "&" else Myself = Left(PATH_INFO & "?" & QUERY_STRING,Instr(PATH_INFO & "?" & QUERY_STRING,"Page=")-1) end if dim taxis taxis="order by id desc " dim i sql="select count(ID) as idCount from ["& datafrom &"]" & datawhere set rs=server.createobject("adodb.recordset") rs.open sql,conn,0,1 idCount=rs("idCount") if(idcount>0) then if(idcount mod pages=0)then pagec=int(idcount/pages) else pagec=int(idcount/pages)+1 end if sql="select id from ["& datafrom &"] " & datawhere & taxis set rs=server.createobject("adodb.recordset") rs.open sql,conn,1,1 rs.pagesize = pages if page < 1 then page = 1 if page > pagec then page = pagec if pagec > 0 then rs.absolutepage = page for i=1 to rs.pagesize if rs.eof then exit for if(i=1)then sqlid=rs("id") else sqlid=sqlid &","&rs("id") end if rs.movenext next end if if(idcount>0 and sqlid<>"") then sql="select * from ["& datafrom &"] where id in("& sqlid &") "&taxis set rs=server.createobject("adodb.recordset") rs.open sql,conn,0,1 dim tr,td dim ProductName,SmallPicPath,Content Response.Write ""&VbCrLf for tr=1 to 3 Response.Write " "&VbCrLf for td=1 to 5 if StrLen(rs("ProductName"&Language))<=18 then ProductName=rs("ProductName"&Language) else ProductName=StrLeft(rs("ProductName"&Language),16) end If If ISHTML = 1 Then AutoLink = ""&ProName&""&Separated&""&rs("ID")&"."&HTMLName&"" Else AutoLink = "ProductView.asp?ID="&rs("ID")&"" End If SmallPicPath=HtmlSmallPic(rs("GroupID"),rs("SmallPic"),rs("Exclusive")) Response.Write " "&VbCrLf Response.Write " "&VbCrLf Response.Write " "&VbCrLf rs.movenext if rs.eof then exit for next Response.Write " "&VbCrLf if rs.eof then exit for next Response.Write "
"&VbCrLf Response.Write " "&VbCrLf Response.Write " "&VbCrLf Response.Write " "&VbCrLf Response.Write " "&VbCrLf Response.Write " "&VbCrLf Response.Write " "&VbCrLf Response.Write "
"&ProductName&"
"&VbCrLf else response.write "
暂无相关信息
" exit function end if Response.Write ""&VbCrLf Response.Write " "&VbCrLf Response.Write " "&VbCrLf Response.Write " "&VbCrLf Response.Write "
"&VbCrLf Response.Write "共"&idcount&"条记录 页次:"&page&"/"&pagec&" 每页:"&pages&"条记录" & vbCrLf pagenmin=page-pagenc pagenmax=page+pagenc if(pagenmin<1) then pagenmin=1 If ISHTML = 1 Then If ID = "" Then if(page>1) then response.write ("9 ") Else if(page>1) then response.write ("9 ") End If Else if(page>1) then response.write ("9 ") End If if page-(pagenc*2+1)<=0 then pageprevious=1 else pageprevious=page-(pagenc*2+1) end If If ISHTML = 1 Then If ID = "" Then if(pagenmin>1) then response.write ("3 ") Else if(pagenmin>1) then response.write ("3 ") End If Else if(pagenmin>1) then response.write ("3 ") End If if(pagenmax>pagec) then pagenmax=pagec for i = pagenmin to pagenmax if(i=page) then response.write (" "& i &" ") Else If ISHTML = 1 Then If ID = "" Then response.write ("["& i &"]") Else response.write ("["& i &"]") End If Else response.write ("["& i &"]") End If end if next if page+(pagenc*2+1)>=pagec then pagenext=pagec else pagenext=page+(pagenc*2+1) end If If ISHTML = 1 Then If ID = "" Then if(pagenmax: ") if(page:") Else if(pagenmax: ") if(page:") End If Else if(pagenmax: ") if(page:") End If Response.Write "
"&VbCrLf rs.close set rs=nothing end function %>