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

📄 untitled_002d1_jsp.java

📁 用JSP制作的个人网站
💻 JAVA
📖 第 1 页 / 共 3 页
字号:
package org.apache.jsp;

import javax.servlet.*;
import javax.servlet.http.*;
import javax.servlet.jsp.*;
import java.sql.*;
import liangjuyan.conndb;
import liangjuyan.chStr;

public final class Untitled_002d1_jsp extends org.apache.jasper.runtime.HttpJspBase
    implements org.apache.jasper.runtime.JspSourceDependent {

  private static java.util.Vector _jspx_dependants;

  public java.util.List getDependants() {
    return _jspx_dependants;
  }

  public void _jspService(HttpServletRequest request, HttpServletResponse response)
        throws java.io.IOException, ServletException {

    JspFactory _jspxFactory = null;
    PageContext pageContext = null;
    HttpSession session = null;
    ServletContext application = null;
    ServletConfig config = null;
    JspWriter out = null;
    Object page = this;
    JspWriter _jspx_out = null;
    PageContext _jspx_page_context = null;


    try {
      _jspxFactory = JspFactory.getDefaultFactory();
      response.setContentType("text/html; charset=gb2312");
      pageContext = _jspxFactory.getPageContext(this, request, response,
      			"", true, 8192, true);
      _jspx_page_context = pageContext;
      application = pageContext.getServletContext();
      config = pageContext.getServletConfig();
      session = pageContext.getSession();
      out = pageContext.getOut();
      _jspx_out = out;

      out.write("\r\n");
      out.write("\r\n");
      out.write("\r\n");

  conndb conn = new conndb();
  chStr chStr=new chStr();
  String username=(String)session.getAttribute("username");
  ResultSet rs_haha = conn.executeQuery("select top 10 id,title ,detail from haha ");
  int s_id = 0;
  String s_title="";
  String s_detail="";
   ResultSet rs_fuzhuang = conn.executeQuery("select *  from fuzhuang ");
  int s_fuzhuangid=0;
   String s_fwupinming ="";
  String s_fyanse="";
  String s_fchangjia ="";
  String s_fcailiao = "";
  String s_fshiyongnianxian = "";
  String s_fshengchanriqi = "";
  String s_fgoumaichishu = "";
  String s_ftuijianzhishu = "";
  String s_fyoudian = "";
  String s_ftupian="";
  String s_fprice="";
  ResultSet rs_shipin = conn.executeQuery("select *  from shipin ");
  int s_shipinid = 0;
  String s_swupinming = "";
  String s_syanse= "";
  String s_schangjia = "";
  String s_scailiao = "";
  String s_sshiyongnianxian = "";
  String s_sshengchanriqi = "";
  String s_sgoumaichishu = "";
  String s_stuijianzhishu = "";
  String s_syoudian = "";
  String s_stupian="";
  String s_sprice="";
  ResultSet rs_shenghuoyongpin = conn.executeQuery("select * from shenghuoyongpin ");
  int s_shenghuoyongpinid = 0;
  String s_hwupinming = "";
  String s_hyanse= "";
  String s_hchangjia = "";
  String s_hcailiao = "";
  String s_hshiyongnianxian = "";
  String s_hshengchanriqi = "";
  String s_hgoumaichishu = "";
  String s_htuijianzhishu = "";
  String s_hyoudian = "";
  String s_htupian="";
   String s_hprice="";
  ResultSet rs_qita = conn.executeQuery("select  *  from qita ");
  int s_qitaid = 0;
  String s_qwupinming = "";
  String s_qyanse= "";
  String s_qchangjia = "";
  String s_qcailiao = "";
  String s_qshiyongnianxian = "";
  String s_qshengchanriqi = "";
  String s_qgoumaichishu = "";
  String s_qtuijianzhishu = "";
  String s_qyoudian = "";
  String s_qtupian="";
  String s_qprice="";
  ResultSet rs_s = conn.executeQuery("select * from type_detail");
  int type_id = 0;
  String type_name="";
   ResultSet rs_shi= conn.executeQuery("select * from stype_detail");
  int stype_id = 0;
  String stype_name="";
 ResultSet rs_sheng = conn.executeQuery("select * from htype_detail");
  int htype_id = 0;
  String htype_name="";
 ResultSet rs_qi = conn.executeQuery("select * from qtype_detail");
  int qtype_id = 0;
  String qtype_name="";
  
      out.write("\r\n");
      out.write("\r\n");
      out.write("<html>\r\n");
      out.write("<head>\r\n");
      out.write("<title></title>\r\n");
      out.write("<meta http-equiv=\"Content-Type\" content=\"text/html; charset=gb2312\">\r\n");
      out.write("<style type=\"text/css\">\r\n");
      out.write(".style2 {color: #FF3300}\r\n");
      out.write(".style7 {color: #000000}\r\n");
      out.write("</style>\r\n");
      out.write("</head>\r\n");
      out.write("<body>\r\n");
      out.write("<table width=\"760\" height=\"934\" border=\"0\" align=\"center\" cellpadding=\"0\" cellspacing=\"0\" bgcolor=\"#FFFFFF\">\r\n");
      out.write("  <tr>\r\n");
      out.write("    <td height=\"404\" valign=\"top\">\r\n");
      out.write("     ");
      org.apache.jasper.runtime.JspRuntimeLibrary.include(request, response, "daohang.jsp", out, false);
      org.apache.jasper.runtime.JspRuntimeLibrary.include(request, response, "dz.jsp", out, false);
      org.apache.jasper.runtime.JspRuntimeLibrary.include(request, response, "zhongjian.jsp", out, false);
      out.write("\r\n");
      out.write("    <table width=\"760\" height=\"453\" border=\"0\" align=\"center\" cellpadding=\"0\" cellspacing=\"0\">\r\n");
      out.write("        <tr>\r\n");
      out.write("          <td width=\"133\" height=\"453\" valign=\"top\"> ");
      org.apache.jasper.runtime.JspRuntimeLibrary.include(request, response, "aa.jsp", out, false);
      out.write("       </td>\r\n");
      out.write("          <td width=\"482\" valign=\"top\">\r\n");
      out.write("            <table width=\"100%\" height=\"452\"  cellpadding=\"0\" cellspacing=\"0\" border=\"1\" bordercolor=\"#cccccc\">\r\n");
      out.write("              <tr>\r\n");
      out.write("                <td height=\"418\" valign=\"top\">\r\n");
      out.write("                  <table width=\"100%\" border=\"1\" cellpadding=\"0\" cellspacing=\"0\" bordercolor=\"#cccccc\" bgcolor=\"#f1f5ff\">\r\n");
      out.write("                    <tr>\r\n");
      out.write("                      <td height=\"34\" colspan=\"11\" valign=\"top\" background=\"images/zuihou.png\" width=\"556\">   服装</td>\r\n");
      out.write("                    </tr>\r\n");
      out.write("                    <tr>\r\n");
      out.write("                      <td width=\"9%\"><div align=\"center\">编号</div></td>\r\n");
      out.write("                      <td width=\"10%\" height=\"27\"><div align=\"center\">物品名</div></td>\r\n");
      out.write("                      <td width=\"9%\"><div align=\"center\">颜色</div></td>\r\n");
      out.write("                      <td width=\"9%\"><div align=\"center\">厂家</div></td>\r\n");
      out.write("                      <td width=\"9%\"><div align=\"center\">材料</div></td>\r\n");
      out.write("                      <td width=\"9%\"><div align=\"center\">使用年限</div></td>\r\n");
      out.write("                      <td width=\"9%\"><div align=\"center\">生产日期</div></td>\r\n");
      out.write("                      <td width=\"9%\"><div align=\"center\">购买次数</div></td>\r\n");
      out.write("                      <td width=\"9%\"><div align=\"center\">推荐指数</div></td>\r\n");
      out.write("                      <td width=\"9%\"><div align=\"center\">优点</div></td>\r\n");
      out.write("                      <td width=\"9%\"><div align=\"center\">价格</div></td>\r\n");
      out.write("                    </tr>\r\n");
      out.write("     ");

     String str=(String)request.getParameter("Page");
        if(str==null){
	    str="0";
                        }
          int pagesize=2;
         rs_fuzhuang.last();
    int RecordCount=rs_fuzhuang.getRow();
 int maxPage=0;
 maxPage=(RecordCount%pagesize==0)?(RecordCount/pagesize):(RecordCount/pagesize+1);

  int Page=Integer.parseInt(str);
   if(Page<1){
	Page=1;}
        else{
	if(Page>maxPage){
		Page=maxPage;
	}
}
rs_fuzhuang.absolute((Page-1)*pagesize+1);
for(int i=1;i<=pagesize;i++){
 s_fuzhuangid=rs_fuzhuang.getInt(1);
                    s_fwupinming = rs_fuzhuang.getString(2);
                      s_fyanse = rs_fuzhuang.getString(3);
                       s_fchangjia = rs_fuzhuang.getString(4);
                        s_fcailiao = rs_fuzhuang.getString(5);
                         s_fshiyongnianxian = rs_fuzhuang.getString(6);
                          s_fshengchanriqi = rs_fuzhuang.getString(7);
                          s_fgoumaichishu= rs_fuzhuang.getString(8);
                           s_ftuijianzhishu= rs_fuzhuang.getString(9);
                            s_fyoudian= rs_fuzhuang.getString(10);
                             s_fprice= rs_fuzhuang.getString(14);
                     if (username==null || username==""){
      out.write("\r\n");
      out.write("                    <tr>\r\n");
      out.write("                      <td><a href=\"fuzhuang_detail.jsp?ID=");
      out.print(s_fuzhuangid);
      out.write('"');
      out.write('>');
      out.print(s_fuzhuangid);
      out.write("</a></td>\r\n");
      out.write("                      <td height=\"31\">");
      out.print(s_fwupinming);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_fyanse);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_fchangjia);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_fcailiao);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_fshiyongnianxian);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_fshengchanriqi);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_fgoumaichishu);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_ftuijianzhishu);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_fyoudian);
      out.write("</td>\r\n");
      out.write("                      <td><div align=\"center\" class=\"style2\"><strong>请先登陆</strong></div></td>\r\n");
      out.write("                    </tr>\r\n");
      out.write("                    ");
}else{
      out.write("\r\n");
      out.write("                    <tr>\r\n");
      out.write("                      <td><a href=\"fuzhuang_detail.jsp?ID=");
      out.print(s_fuzhuangid);
      out.write('"');
      out.write('>');
      out.print(s_fuzhuangid);
      out.write("</a></td>\r\n");
      out.write("                      <td height=\"31\">");
      out.print(s_fwupinming);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_fyanse);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_fchangjia);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_fcailiao);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_fshiyongnianxian);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_fshengchanriqi);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_fgoumaichishu);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_ftuijianzhishu);
      out.write("</td>\r\n");
      out.write("                     <td>");
      out.print(s_fyoudian);
      out.write("</td>\r\n");
      out.write("                      <td>");
      out.print(s_fprice);
      out.write("</td>\r\n");
      out.write("                    </tr> ");
}
                    try{
		if(!rs_fuzhuang.next()){break;}
		}
        catch(Exception e){}
                       }
      out.write("\r\n");
      out.write("                    <tr>\r\n");
      out.write("                      <td height=\"31\" colspan=\"11\"><table width=\"100%\" >\r\n");
      out.write("                        <tr>\r\n");
      out.write("                           <td align=\"right\"><span class=\"style7\">当前页数:</span>[");
      out.print(Page);
      out.write('/');
      out.print(maxPage);
      out.write("]&nbsp;\r\n");
      out.write("\t");
if(Page>1){
      out.write("\r\n");
      out.write("\t<a href=\"index.jsp?Page=1\" class=\"style7\">第一页</a> <a href=\"index.jsp?Page=");
      out.print(Page-1);
      out.write("\" class=\"style7\">上一页</a>\r\n");
      out.write("\t");

	}
	if(Page<maxPage){
	
      out.write("\r\n");

⌨️ 快捷键说明

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