<% GotoPage = Request("GotoPage") if GotoPage = "" then GotoPage = 1 pagesize = 16 branchCode = Request("branchCode") search_category = Request("search_category") searchString = Request("searchString") 'If branchCode = "" Then branchCode = "" If branchCode <> "" Then search_qry = " and branchCode = '"&branchCode&"'" End If If search_category <> "" And searchString <> "" Then search_qry = " and "&search_category&" like '%"&searchString&"%'" End If SQL = "SELECT count(IDX) as recCount FROM tbl_custom where 1=1 " & search_qry 'Response.write SQL SET Rs = DBCON.EXECUTE(SQL) recordCount = Rs(0) Rs.close : Set Rs = nothing pagecount = int((recordCount-1)/pagesize) +1 SQL = "SELECT TOP " & pagesize & " * FROM tbl_custom " SQL = SQL & " WHERE 1=1 "&search_qry&" and IDX not in " SQL = SQL & "(SELECT TOP " & ((GotoPage - 1) * pagesize) & " IDX FROM tbl_custom" SQL = SQL & " where 1=1 "&search_qry&" ORDER BY IDX desc) order by idx desc" 'Response.write SQL Set RS = Dbcon.Execute(SQL) %>
À¯¾Ø¾ÆÀÌ °í°´¸¸Á·¼¾ÅÍ

°í°´¼Ò¸®ÇÔ

  • Home
  • °í°´¸¸Á·¼¾ÅÍ
  • °í°´¼Ò¸®ÇÔ
<% i = 0 j = 0 DO UNTIL RS.EOF loop_num = loop_num + 1 If j = 2 Then j = 0 view_num = int(recordCount)-(int(pagesize)*(int(GotoPage)-1)) - loop_num + 1 idx = RS("idx") user_id = RS("user_id") user_name = RS("user_name") user_email = RS("user_email") bbs_type_u = RS("bbs_type_u") store_type = RS("store_type") b_subject = RS("b_subject") b_writedate = RS("b_writedate") b_re_writedate = RS("b_re_writedate") b_writedate = Left(b_writedate,10) b_writedate = replace(b_writedate,"-",".") b_re_writedate = Left(b_re_writedate,10) b_re_writedate = replace(b_re_writedate,"-",".") %> <% i = i + 1 j = j + 1 RS.MOVENEXT Loop RS.CLOSE() %>
¹øÈ£ ÀÇ·á»ó´ã Á¦¸ñ ÀÛ¼ºÀÚ µî·ÏÀÏ
<%=view_num%> <% If store_type = "1" Then %> °­³²Á¡ <% End If %> <% If store_type = "3" Then %> Àá½ÇÁ¡ <% End If %> <% If store_type = "5" Then %> Àá½ÇÁ¡ <% End If %> <% If store_type = "6" Then %> ¿Õ½Ê¸®Á¡ <% End If %> <% If store_type = "4" Then %> ÆÇ±³Á¡ <% End If %> <% If store_type = "2" Then %> ¼ö¿øÁ¡ <% End If %> <% If store_type = "7" Then %> ¸íµ¿Á¡ <% End If %> <% If store_type = "8" Then %> ±¤±³Á¡ <% End If %> <% If store_type = "9" Then %> ½ÅÃÌÁ¡ <% End If %> <% If bbs_type_u = "1" And Trim(Session("id")&"")="" Then %> <%=b_subject%> <% Else %> <%=b_subject%> <% End If %> <%=user_name%> <%=b_writedate%>
<% Set listNum = New PageNavi listNum.Initial "cscenter01.asp?vSort="&vSort&"&gSort="&gSort&"&sSort="&sSort&"&vKeyType="&vKeyType&"&vUserName="&vUserName&"&vUserId="&vUserId&"&branchCode="&branchCode&"&vSid1="&vSid1&"&vSid2="&vSid2,10,gotopage,pagecount,search_category,searchString,optionstr,"","" listNum.pagePrint Set listNum = nothing %> ±Û¾²±â