<% '//****************파라미터정보*************************** If a_ad_cms = "Y" then a_ad_cms_url = "ad_cms.asp?a_num=" & a_num & "&" & page_info Else a_ad_cms_url = "#" End if '//******************************************************* '//****************페이징정보***************************** v_pagesize = a_displaysu '//리스트 화면에 보여줄 갯수 v_block = 10 '//페이징 갯수 length = 30 '//내용 길이 '//******************************************************* '//****************테이블 기본 환경설정******************* is_tablename = a_tablename '//테이블명 R_Fields = "b_num, b_type, b_id, b_name, b_pwd, b_subject, b_email, b_jumin, b_phone1, b_phone2, b_phone3, b_cate, b_catename, b_noticechk, b_content, b_ip, b_count, b_look, b_open, b_ref, b_step, b_level, b_regdate, b_chuchun, b_sbjclr, b_sdate, b_edate, b_temp1, b_temp2, b_temp3, b_temp4, b_file1, b_file2, b_file3, b_file4, b_file5,b_c_count" '//레코드필드 pk_Field = "b_num" opt_where_str = "" '; //기본조건이 있을때 사용..없으면 '' 처리 '//$orderby_str = " ORDER BY "&pk_Field&" DESC "; //정렬 orderby_str = " ORDER BY b_ref desc, b_step asc " '//정렬 '//******************************************************* '//****************옵션 부분****************************** if trim(v_keyword) <> "" and v_search <> "" then '//검색어가 있다면 search_str = " AND " & v_search & " like '%" & replace(v_keyword,"'","''") & "%'" End if If is_ad_cms <> "Y" then '//관리자가아닐때 실행할것들... if a_member = "Y" then '//회원제 사용일때 search_str2 = " AND b_id = '" & SESSION("ss_m_id") & "' " if SESSION("ss_m_id") = "" Then Call goMessage_board("로그인 후 사용하세요", "/content/board/manager.asp?a_num="&a_num , "", "", a_num) End if End if search_str5 = " AND b_look = 'Y' " End if '//포토갤러리 일때// 답변글을 가지고 오지 않는다.. search_str3 =" and b_type = 'N' " '//기간설정 사용시.. if a_date_list = "Y" then If a_sdate <> "" And a_edate = "" then search_str4 = " and left(b_regdate,10) >= '" & a_sdate & "' " ElseIf a_sdate <> "" And a_edate <> "" then search_str4 = " and left(b_regdate,10) >= '" & a_sdate & "' and left(b_regdate,10) <= '" & a_edate & "'" End if End If '//분류기능 사용시.. if a_cate = "Y" and v_cate <> "" then search_str6 = " AND b_cate = " And v_cate End If '//******************************************************* '//****************전체 레코드 수 뽑기******************** SQL_T = "select count(" & pk_Field & ") as " & pk_Field & " from " & is_tablename & " where b_noticechk = '' " SQL_T = SQL_T & search_str & search_str2 & search_str3 & search_str4 & search_str5 & search_str6 '//검색옵션 Set row = dbcon.execute( sql_t ) recordcount = row(pk_Field) v_totalpage = fix( (recordcount-1)/ v_pagesize)+1 '전체덩어리갯수 If v_page = "" then v_page = 1 ElseIf v_page < 1 then v_page = 1 ElseIf Int(v_page) > v_totalpage then v_page = v_totalpage End if '//******************************************************* strSQL = "select Top " & v_pagesize & " " & R_Fields & " from " & is_tablename & " where b_noticechk = '' " strSQL = strSQL & search_str & search_str2 & search_str3 & search_str4 & search_str5 & search_str6 '검색옵션 strSQL = strSQL & " and " & pk_Field & " not in" strSQL = strSQL & "(select top " & ( v_pagesize * (v_page - 1) ) & " " & pk_Field & " from " & is_tablename & " where b_noticechk = '' " & search_str & search_str2 & search_str3 & search_str4 & search_str5 & search_str6 strSQL = strSQL & " " & orderby_str & ")" & orderby_str 'response.write strSQL 'response.end Set rs = dbcon.execute( strSQL ) If rs.bof Or rs.eof Then list_data = Null vCnt = 0 Else list_data = rs.getrows vCnt = UBound(list_data, 2) End if Set rs = Nothing %>
<%If a_ad_cms = "Y" then%> <%If SESSION("ss_m_id") = "" then%> <%else%> <%End if%> 전체 <%=recordcount%>개 (페이지 <%=v_page%>/<%=v_totalpage%>) <%else%> 전체 <%=recordcount%>개 (페이지 <%=v_page%>/<%=v_totalpage%>) <%End if%>
<%If is_ad_cms = "Y" then%>
<%End if%>
<% If IsNull( list_data ) Then %> <% else If v_page = 1 then num = recordcount else num = recordcount - ((v_page -1) * v_pagesize) End if For i = 0 To UBound(list_data, 2) '//필드갯수만큼 ($Query_Fields).가지고온다.. Call arr2Value(R_Fields, "list_data", i) '//답변표시 If b_type = "R" then b_type_str = "" '//초기화 For xx=1 To b_level If xx <> 1 Then b_type_str = b_type_str & "   " next b_type_str = b_type_str & "" Else b_type_str = "" End if '//공개/비공개 If a_type = "Y" Or a_type = "T" then '//사용하면 If b_open = "N" Or a_type = "T" then '//비공개이면 b_open_str = "비밀글" else '//공개이면 b_open_str = "" End if Else b_open_str = "" End if '//사용/중지 If b_look = "Y" then tr_clr = "" tr_clr2="" ElseIf b_look = "N" then tr_clr = " class=""data_none""" tr_clr2 = " data_none" End if '//댓글사용시 If a_command = "Y" then if b_c_count <> "0" then a_command_str = "(" & b_c_count & ")" Else a_command_str = "" End if Else a_command_str = "" End if If IsNull(b_file1) Or b_file1 = "" then '//없으면.. tp_dir = a_level & "/img/" b_file1 = "no.gif" else '//첨부파일이 있으면.. b_file1_arry = split( b_file1, "." ) fileend = LCase( b_file1_arry( UBound(b_file1_arry) ) ) If fileend = "gif" or fileend = "jpg" then '//이미지 파일이면.. 'If fileend = "gif" then tp_dir = "/data/board/" & a_tablename & "/" 'else ' tp_dir = "/data/board/" & a_tablename & "/thum/" 'End if else '//이미지파일 아닐때.. tp_dir = a_level & "/img/" b_file1 = "no.gif" End if End if tot_file = tp_dir & b_file1 b_subject_str = remove_tags( b_subject ) b_subject_str = StringToHTML( b_subject_str, 13, false ) %> > <%=b_subject%>
<%If is_ad_cms = "Y" then '//관리권한이 있을때만 보인다%> <%End if%> <%=b_type_str%> <%If b_type="N" And a_cate = "Y" then response.write "" & b_cate_str(b_cate) & ""%> <%=b_subject_str%> <%=a_command_str%> <%=get_newimg2(left(b_regdate,10), a_new)%> <%=b_open_str%>
<% If i > 0 And i Mod 4 = 3 And i
" else response.write "" End If num = num - 1 next End if %>
<%=replace( tit_name, " | ", "")%>
등록된 내용이 없습니다.
<%If is_ad_cms = "Y" then '//관리권한이 있을때만 보인다%> <%End if%>
목록 <%If is_write = "Y" then%> 쓰기 <%End if%>
<% If is_ad_cms = "Y" then %>
<% End if%>
<%page2("list.asp?a_num="& a_num)%>