<!--#include file="../Include/Conn.asp" -->
<!--#include file="Images/club.jpg"-->
<!--#include file="../Include/const.asp" -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>会员俱乐部:</title>
<link href="../css/member.css" rel="stylesheet" type="text/css">
<script language="JavaScript" type="text/JavaScript">
<!--



function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
//-->
</script>
</head>

<body>
<!--#include file="../include/top.asp" -->
<!--#include file="../Include/member_Top.asp" -->
<!--#include file="club_top.asp" -->
<TABLE cellSpacing=0 cellPadding=0 width=780 align=center border=0>
  <TBODY>
    <TR> 
      <TD width=780 bgColor=#ffffff><IMG height=114 
      src="Images/test_indextitle1.gif" width=780></TD>
    </TR>
  </TBODY>
</TABLE>
<TABLE cellSpacing=0 cellPadding=0 width=780 align=center 
background=../Images/test_indextitle2.gif border=0>
  <TBODY>
    <TR> 
      <TD width=303 height=37>&nbsp;</TD>
      <TD vAlign=bottom align=middle width=477 
      height=37>
	  <%
					dim PerPage
					set rs_c=server.createobject("adodb.recordset")
					sql_c="select * from t_test"
					rs_c.open sql_c,conn,1,1
					'flag="尚未处理"
                    PerPage=30
				
                   '假如没有数据时
                 ' If rs_c.eof and rs_c.bof then
                  ' response.write "<p align='center'><font color='#ff0000'>还没任何新闻</font></p>"
                 ' response.end
                 ' End if
					'取得页数,并判断用户输入的是否数字类型的数据，如不是将以第一页显示
                    text="0123456789"
                    Rs_c.PageSize=PerPage
					
                    for i=1 to len(request("page"))
                    checkpage=instr(1,text,mid(request("page"),i,1))
                    if checkpage=0 then
                    exit for
                    end if
                    next

                  If checkpage<>0 then
                  If NOT IsEmpty(request("page")) Then
                  CurrentPage=Cint(request("page"))
                  If CurrentPage < 1 Then CurrentPage = 1
                  If CurrentPage > Rs_c.PageCount Then CurrentPage = Rs_c.PageCount
                  Else
                  CurrentPage= 1
                  End If
                 If not Rs_c.eof Then Rs_c.AbsolutePage = CurrentPage end if
                 Else
                 CurrentPage=1
                 End if					
				%>
	  总共有&nbsp;<B><%=Cstr(rs_c.RecordCount)%></B>&nbsp;条心灵测试，每页&nbsp;<B><%=PerPage%></B>&nbsp;条，共&nbsp;<B><%=Cstr(rs_c.pagecount)%></B>&nbsp;页，当前是第&nbsp;<B><%=CurrentPage%></B>&nbsp;页</TD>
    </TR>
    <TR> 
      <TD colSpan=2 height=48>&nbsp;</TD>
    </TR>
  </TBODY>
</TABLE>
<TABLE cellSpacing=0 cellPadding=0 width=780 align=center border=0>
  <TBODY>
    <%
if not rs_c.eof then
i=0
do while not rs_c.eof
%>
    <TR> 
      <TD width=10 bgColor=#f6f6f6 height=25></TD>
      <TD width=16 bgColor=#ffffff height=25></TD>
      <TD width=345 bgColor=#f6f6f6 height=25>&nbsp;<IMG height=12 
      src="Images/test_ico.gif" width=12 align=absMiddle>&nbsp;<A 
      title=<%=rs_c("F_Title")%>
      onclick="window.open(this,'','width=400,height=380,top=100,left=100,location=no,menubar=no,toolbar=no,titlebar=no,scrollbars=no');return false;" 
      href="club_viewtest.asp?id=<%=rs_c("F_id")%>" 
      target=_blank><U><%=rs_c("F_Title")%></U></A><FONT color=#999999>（点击：<%=rs_c("F_Hits")%>）</FONT></TD>
      <%
	   i=i+1
	  if i >= Perpage then exit do
      rs_c.movenext
	  if rs_c.eof then exit do
	  %>
      <TD width=31 bgColor=#ffffff height=25></TD>
      <TD width=345 bgColor=#f6f6f6 height=25>&nbsp;<IMG height=12 
      src="Images/test_ico.gif" width=12 align=absMiddle>&nbsp;<A 
      title=<%=rs_c("F_Title")%>
      onclick="window.open(this,'','width=400,height=380,top=100,left=100,location=no,menubar=no,toolbar=no,titlebar=no,scrollbars=no');return false;" 
      href="club_viewtest.asp?id=<%=rs_c("F_id")%>" 
      target=_blank><U><%=rs_c("F_Title")%></U></A><FONT color=#999999>（点击：<%=rs_c("F_Hits")%>）</FONT></TD>
      <TD width=22 bgColor=#ffffff height=25></TD>
      <TD width=11 bgColor=#f6f6f6 height=25></TD>
    </TR>
    <%
	 i=i+1
if i >= Perpage then exit do
rs_c.movenext
loop
end if
%>
    <TR> 
      <TD bgColor=#f6f6f6 height=30></TD>
      <TD bgColor=#ffffff height=30></TD>
      <TD align=middle bgColor=#ffffff colSpan=3 height=30>
        <% If currentpage > 1 Then  %>
        &nbsp;<a href='club_test.asp?page=<%=cstr(1)%>'><SPAN style="FONT-SIZE: 15px; COLOR: #000000; FONT-FAMILY: webdings">9</SPAN></a> 
        &nbsp;<a href='club_test.asp?page=<%=Cstr(currentpage-1)%>'><SPAN style="FONT-SIZE: 15px; COLOR: #000000; FONT-FAMILY: webdings">7</SPAN></a> 
        &nbsp; 
        <% Else  %>
        &nbsp;<SPAN style="FONT-SIZE: 15px; COLOR: #000000; FONT-FAMILY: webdings">9</SPAN> 
        &nbsp;<SPAN style="FONT-SIZE: 15px; COLOR: #000000; FONT-FAMILY: webdings">7</SPAN> 
        <% end if %>
        <%
			  if rs_c.pagecount>8 then
			  n_star=currentpage
			  n_end=currentpage+7
			  else
			  n_star=1
			  n_end=rs_c.pagecount			  
			  end if
			  %>
        <% FOR n=n_star to n_end %>
        <% if n>rs_c.pagecount then  exit for  end if%>
        &nbsp;<a href='club_test.asp?page=<%=n%>'><FONT color=#ff0000><B><%=n%></B></FONT></a> 
        <%
			  next
			 %>
        <% If currentpage < Rs_c.PageCount Then %>
        &nbsp;<a href='club_test.asp?page=<%=Cstr(currentPage+1)%>'><SPAN  style="FONT-SIZE: 15px; COLOR: #000000; FONT-FAMILY: webdings">8</SPAN></a> 
        &nbsp;<a href='club_test.asp?page=<%=Cstr(Rs_c.PageCount)%>'><SPAN  style="FONT-SIZE: 15px; COLOR: #000000; FONT-FAMILY: webdings">:</SPAN></a> 
        <% else %>
        &nbsp;<SPAN  style="FONT-SIZE: 15px; COLOR: #000000; FONT-FAMILY: webdings">8</SPAN> 
        &nbsp;<SPAN  style="FONT-SIZE: 15px; COLOR: #000000; FONT-FAMILY: webdings">:</SPAN> 
        <% end if
				rs_c.close
				set rs_c=nothing
				 %>
      </TD>
      <TD bgColor=#ffffff height=30></TD>
      <TD bgColor=#f6f6f6 height=30></TD>
    </TR>
    <TR> 
      <TD bgColor=#ffffff height=5></TD>
      <TD bgColor=#ffffff height=5></TD>
      <TD align=middle bgColor=#ffffff colSpan=3 height=5></TD>
      <TD bgColor=#ffffff height=5></TD>
      <TD bgColor=#ffffff height=5></TD>
    </TR>
  </TBODY>
</TABLE>
<table width="780" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="10" bgcolor="#FFFFFF"></td>
  </tr>
</table>
<table width="780" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td height="5" bgcolor="#FFFFFF"></td>
  </tr>
</table>
<!--#include file="../Include/Bottom.asp" -->
</body>
</html>


