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

📄 admin_wishlist.jsp

📁 j2ee专业项目实例开发原代码j2ee专业项目实例开发 j2ee专业项目实例开发
💻 JSP
字号:
<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta http-equiv="Content-Language" content="en-us">
<title>Wishlist Page</title>
</head>

<body bgcolor="#C0C0C0" topmargin="0" background="http:\\localhost:8000\music\Background.bmp" >

<table border="0" width="100%">
  <tr>
    <td width="100%">
      <table border="0" width="97%" height="19">
        <tr>
          <td width="18%" height="13" valign="middle" align="right">
      <font face="Arial" size="5" color="#800000"><b><i>eMusicWorld-----&gt; The World of Music</i></b></font>
          </td>
        </tr>
      </table>
    </td>
  </tr>
</table>

<form method="get" action="http://localhost:8000/music/admin_home_page.htm">
<table border="0" width="100%">
 
  <tr>
    <td width="100%"><table border="0" width="100%" height="19">
        <tr>
          <td width="9%" height="13" valign="middle" align="center"><font face="Arial" size="2" color="#800000"><b><a HREF="welcome_page.htm">Home</a></b></font></td>
          <td width="10%" height="13" valign="middle" align="center"></td>
          <td width="19%" height="13" valign="middle" align="center"></td>
          <td width="13%" height="13" valign="middle" align="center"></td>
          <td width="13%" height="13" valign="middle" align="center"></td>
        	<td width="11%" height="13" valign="middle" align="center"></td>
 			<td width="10%" height="13" valign="middle" align="center"></td>
          <td width="9%" height="13" valign="middle" align="center"><font face="Arial" size="2" color="#800000"><b><a HREF="http://localhost:8000/music/logout_page.jsp">Logout</b></font></td>
          <td width="9%" height="13" valign="middle" align="center"><font face="Arial" size="2" color="#800000"><b><a HREF="http://localhost:8000/music/admin_home_page_old.htm">Help</a></b></font></td>
        </tr>
      </table>
    </td>
  </tr>
</table>

<table border="1" width="100%" height="353">
  <tr>
      <td width="15%" height="347" valign="top">
    
<p><font face="Arial" size="2" color="#800000"><b><a HREF="http://localhost:8000/music/admin_del_user.jsp">Delete User</a></b></font></p>
<p><font face="Arial" size="2" color="#800000"><b><a HREF="http://localhost:8000/ItemContext/ItemAlias">Add Item</a></b></font></p>
<p><font face="Arial" size="2" color="#800000"><b><a HREF="http://localhost:8000/music/admin_mod_item.jsp">Modify Item</a></b></font></p>
<p><font face="Arial" size="2" color="#800000"><b>Sales Reports<br>---<a HREF="http://localhost:8000/music/daily_sales_report.jsp">Choose a Date</a><br>---<a HREF="http:\\localhost:8000\weekly_sales_report.jsp">Previous
Week</a><br>---<a HREF="http://localhost:8000/music/monthly_sales_report.jsp">Previous Month</a></b></font></p>
<p><font face="Arial" size="2" color="#800000"><b><a HREF="http://localhost:8000/music/admin_wishlist.jsp">View Wishlist</a></b></font></p>
<p><font face="Arial" size="2" color="#800000"><b><a HREF="http://localhost:8000/music/admin_messages.jsp">View Messages</a></b></font></p>
   

	</td>
  
    <td width="85%" height="347" valign="top">

<p align="center">
<b><u><font face="Arial" color="#800000" size="2">User's Wishlist</font></u></b></p>
<table border="1" width="86%">
  <tr>
    <td width="20%"><font face="Arial" size="2" color="#800000"><b>User Name</b></font></td>
    <td width="15%"><font face="Arial" size="2" color="#800000"><b>Item Code</b></font></td>
    <td width="15%"><font face="Arial" size="2" color="#800000"><b>Item Desc</b></font></td>
    <td width="10%"><font face="Arial" size="2" color="#800000"><b>Quantity</b></font></td>
    <td width="20%"><font face="Arial" size="2" color="#800000"><b>Listed on</b></font></td>
  </tr>
	<%@ page import="java.util.*" %>
	<%@ page import="java.sql.*" %>
	<%@ page import="java.text.*" %>
	<%@ page import="java.sql.Date" %>

	<%@ page language = "java" %> 
	<%
	try{
	Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
	Connection connect, connect1;

	connect=DriverManager.getConnection("jdbc:odbc:RegisterDataSource","wasiqr","bhalbabatu");
	
	Statement state;
	
	state = connect.createStatement();
	
	String strQuery1 = "select User_name, Item_code, Qty, Wish_Date from Wishlist_Info Group by User_name, Item_code, Qty, Wish_Date order by User_name asc";
	
	ResultSet result = state.executeQuery(strQuery1);
	String username, itemcode, itemdesc, qty, wishdate;
	while(result.next())				
	{	
		username=result.getString("User_name");
		
		itemcode=result.getString("Item_code");


		connect1=DriverManager.getConnection("jdbc:odbc:RegisterDataSource","wasiqr","bhalbabatu");
		itemcode=itemcode.trim();
		Statement state1;
		state1 = connect1.createStatement();
		String strQuery2 = "select Item_Desc from Item_Master where Item_Code='"+itemcode+"'";
		ResultSet result1 = state1.executeQuery(strQuery2);
		itemdesc="";
		while(result1.next())
		{
			itemdesc=result1.getString("Item_Desc");
		}

		qty=result.getString("Qty");
		wishdate=result.getString("Wish_Date");
		wishdate=wishdate.substring(0,10);
		out.println("<tr>");
    out.println("<td width=\"20%\"><font face=\"Arial\" size=\"2\" color=\"#800000\">" + username + "</font></td>");
  out.println("<td width=\"15%\"><font face=\"Arial\" size=\"2\" color=\"#800000\">" + itemcode + "</font></td>");
out.println("<td width=\"15%\"><font face=\"Arial\" size=\"2\" color=\"#800000\">" + itemdesc + "</font></td>");
out.println("<td width=\"10%\"><font face=\"Arial\" size=\"2\" color=\"#800000\">" + qty + "</font></td>");
out.println("<td width=\"20%\"><font face=\"Arial\" size=\"2\" color=\"#800000\">" + wishdate + "</font></td>");

      out.println("</tr>");
	connect1.close();
	}
	connect.close();
	}
	catch(Exception e)
	{
		out.println("Exception: " + e + " occured.");
	}
%>
  
</table>

 
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p>
  <table border="0" width="100%">
    <tr>
      <td width="50%" valign="middle" align="right">
  <input type="submit" value="OK" name="ok_button"></td>
      <td width="50%" valign="middle" align="right"></td>
    </tr>
  </table>
</form>

    
  
    </td>
  </tr>
</table>

</body>

</html>

⌨️ 快捷键说明

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