⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ph.jsp

📁 【功能】 1:多用户统计系统
💻 JSP
字号:
<%@page contentType="text/html; charset=gb2312" language="java" import="java.sql.*,java.util.*" errorPage="" %>
<HTML><HEAD><TITLE>湖湘网安统计</TITLE>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<META content="Microsoft FrontPage 4.0" name=GENERATOR>
<LINK href="images/default.css" type=text/css rel=stylesheet></HEAD>
<BODY>
<body bgcolor="#f0f0f0" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<TABLE width=770 align=center bgColor=#f0f0f0 
leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
  <TBODY>
  <TR>
    <TD vAlign=bottom align=right bgColor=#cccccc>[<a href=index.jsp>首页</a>][<A 
      href="admin.jsp">管理区</A>][<A 
      href="reg1.jsp">申请</A>][<a href=ph.jsp>排行</a>]</TD></TR>
  <TR>
    <TD width=770>
      <TABLE height=450 cellSpacing=0 cellPadding=0 width=770 border=0>
        <TBODY>
        <TR>
          <TD vAlign=top width=176>
            <TABLE cellSpacing=0 cellPadding=0 width=150 border=0>
              <TBODY>
              <TR>
                <TD vAlign=top width=150 height=44><IMG height=44 
                  src="images/menu1.jpg" width=150></TD></TR>
              <TR>
                <TD vAlign=top background=images/menu2.jpg height=280>
                  <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
                          <TBODY>
                            <TR> 
                              <TD width="30%" height=25>&nbsp;</TD>
                              <TD width="70%" rowspan="9"> 
                                <TABLE height=19 cellSpacing=0 cellPadding=0 width=15 border=0>
                                  <TBODY>
                                    <TR> 
                                      <TD vAlign=center width=76><img src="images/top.gif" width="67" height="219"></TD>
                                    </TR>
                                  </TBODY>
                                </TABLE></TD>
                            </TR>
                            <TR> 
                              <TD width="30%" height=25>&nbsp;</TD>
                            </TR>
                            <TR> 
                              <TD width="30%" height=25>&nbsp;</TD>
                            </TR>
                            <TR> 
                              <TD width="30%" height=25>&nbsp;</TD>
                            </TR>
                            <TR> 
                              <TD width="30%" height=25>&nbsp;</TD>
                            </TR>
                            <TR> 
                              <TD width="30%" height=25>&nbsp;</TD>
                            </TR>
                            <TR> 
                              <TD width="30%" height=25>&nbsp;</TD>
                            </TR>
                            <TR> 
                              <TD width="30%" height=25>&nbsp;</TD>
                            </TR>
                            <TR> 
                              <TD width="30%" height=25>&nbsp;</TD>
                            </TR>
                            <TR> 
                              <TD width="30%" height=25>&nbsp;</TD>
                              <TD width="70%" 
              height=25>&nbsp;</TD>
                            </TR>
                          </TBODY>
                        </TABLE></TD></TR>
              <TR>
                <TD vAlign=top width=150 height=10><IMG height=10 
                  src="images/menu3.jpg" width=150></TD></TR>
              <TR>
                <TD width=150 background=images/menu4.jpg 
                height=80>&nbsp;</TD></TR>
              <TR>
                <TD vAlign=top width=150 height=14><IMG height=14 
                  src="images/menu5.jpg" width=150></TD></TR></TBODY></TABLE></TD>
          <TD align=middle vAlign=top width=588><BR>
                <TABLE border=0 cellPadding=0 cellSpacing=0>
                  <TBODY> 
                  <TR> 
                    <TD colSpan=2 rowSpan=2 vAlign=top> 
                      <TABLE bgColor=#000000 border=0 cellPadding=0 cellSpacing=0 width=488">
                        <TBODY> 
                        <TR> 
                          <TD bgColor=#ffffff vAlign=top> 
                            <TABLE border=0 cellPadding=0 cellSpacing=0 width="100%">
                              <TBODY> 
                              <TR> 
                                
<br>

<table width="460" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td background="images/graph_border1.gif" height="25" valign="top">
      <b style="font-family: 宋体;line-height: 21px">&nbsp;&nbsp;湖湘网安统计排行榜</b>
    </td>
  </tr>
  <tr>

<script language="JavaScript">
<!--
function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);
// -->
</script>
</head>
<jsp:useBean id="feng" scope="page" class="feng.jdbc" />
<%
Connection con = feng.getConn();
Statement stmt=con.createStatement(ResultSet.TYPE_SCROLL_INSENSITIVE,ResultSet.CONCUR_READ_ONLY);

  int PageSize=15;
  int RecordCount=0;
  int PageCount=0;
  int ShowPage=1;


  String sql="Select * from InfoList";
  ResultSet rs=stmt.executeQuery(sql);

  rs.last();
  RecordCount=rs.getRow();
  PageCount=(RecordCount % PageSize==0)?(RecordCount/PageSize):(RecordCount/PageSize+1);
  String Page=request.getParameter("page");
  if (Page!=null)
  {
        ShowPage=Integer.parseInt(Page);
     if (ShowPage>PageCount)
        ShowPage=PageCount;
     else if(ShowPage<0)
        ShowPage=1;
  }else
        ShowPage=1;
//out.println("<font color='#000080'>&nbsp;共</font><b><font color=red>"+RecordCount+"</font></b><font color='#000080'>个站点</font>");

%>
<td background="images/graph_border2.gif">
      <table width="460" border="0" cellspacing="0" cellpadding="0">
        <tr> 
          <td width="11">&nbsp;</td>
          <td background="images/tablebg.gif" align="center"> 
            <table width="98%" border="0" cellspacing="0" cellpadding="0">
               <tr>
          <td height="20" align="center" nowrap>&nbsp;<strong>网站名称</strong>&nbsp;</td>
                 <td height="20" width="1"></td>
                 <td height="20" align="center" nowrap>&nbsp;&nbsp;&nbsp;<strong>站 点 简 介</strong>&nbsp;&nbsp;&nbsp;</td>
                 <td height="20" width="1"></td>
                 <td height="20" align="center" nowrap>&nbsp;<strong>注册日期</strong>&nbsp;</td>
                 <td height="20" width="1"></td>
                 <td height="20" align="center" nowrap>&nbsp;&nbsp;<strong>统计/计数</strong>&nbsp;&nbsp;</td>
                 <td height="20" width="1"></td>
 </tr>
 <tr>
<%
if (RecordCount>0)
{
rs.absolute((ShowPage-1)*PageSize+1);
for (int i=1;i<=PageSize;i++)
{
  String WZ_Name=rs.getString("Name");
  String WZ_Url=rs.getString("Url");
  String WZ_Num=rs.getString("TotalNum");
  String WZ_Count=rs.getString("cnetNum");
  String StartDate=rs.getString("StartDate");
  String note2=rs.getString("note2");
  String admin=rs.getString("admin");
%>


<td height="20" align="center" class="small" nowrap>
<a href="<%=WZ_Url%>" target=_black title=<%=WZ_Name%>><%=WZ_Name%></a></td>
<td height="20" width="1" bgcolor="#F7EF72"></td>
 <td height="20" align="center" class="small" nowrap> 
<%=note2%>...</td>
<td height="20" width="1" bgcolor="#F7EF72"></td>
 <td height="20" align="center" class="small" nowrap> 
<i><%=StartDate%></i></font></td>
<td height="20" width="1" bgcolor="#F7EF72"></td>
 <td height="20" align="center" class="small" nowrap>
<a href=info.jsp?id=<%=admin%> title="查看综合统计信息"><%=WZ_Num%>/<%=WZ_Count%></a></td>
 </tr>
 <tr>
<%
if (!rs.next())
break;
}
}


%>

</tr>
               <tr>
                  
               </tr>
            </table>
          </td>
          <td width="5"></td>
          <td width="11" background="images/graph_border5.gif">&nbsp;</td>
          <td width="9"></td>
        </tr>
      </table>
    </td>
  </tr>
  <tr>
    <td background="images/graph_border4.gif" height="10"></td>
  </tr>
</table>


<form method="POST" action="ph.jsp">

  <p><input type="hidden" name="fid" size="20" bgColor=#394a5a ></p>

  <p>现在是第 <font color=black ><%=ShowPage%></font> 页 转到<select size="1" name="page">

<%
for (int i=1;i<=PageCount;i++)
{
    out.println(" <option value="+i+">"+i+"页</option>");
}

		 try {
              rs.close();
              stmt.close();
              con.close();
            }
            catch (Exception ex) {
            }
%>
</select>
<input bgColor=#394a5a type="submit" value="转 到" name="B1"></p>
</form>

                                  
                                  <BR>
                                  <BR>
                                </TD>
                              </TR>
                              </TBODY>
                            </TABLE>
                          </TD>
                        </TR>
                        </TBODY>
                      </TABLE>
                    </TD>
                    <TD bgColor=#394a5a height=9 vAlign=top width=10><IMG height=9 src="./images/cooltable_rt.gif" width=10></TD>
                  </TR>
                  <TR>
                    <TD bgColor=#394a5a width=10></TD>
                  </TR>
                  <TR> 
                    <TD bgColor=#8c949c height=10 vAlign=top width=11><IMG height=10 src="./images/cooltable_lb.gif" width=11></TD>
                    <TD bgColor=#8c949c height=10></TD>
                    <TD height=10 vAlign=top width=10><IMG height=10 src="./images/cooltable_rb.gif" width=10></TD>
                  </TR>
                  </TBODY>
                </TABLE>
              </TD>
            </TR>
            </TBODY>
          </TABLE>
        </TD>
      </TR>
      <TR> 
        <TD> 
          <div align="center"></div>
        </TD>
      </TR>
      <TR>
        <TD bgcolor=#CCCCCC>
          <div align="center">copy right by www.hxwa.net 湖湘网安版权所有</div>
        </TD>
      </TR>
      </TBODY>
    </TABLE>
    <BR></BODY></HTML>
<center></center>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -