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

📄 manager_meeting_person_left.jsp

📁 一个JSP范例
💻 JSP
字号:
<%@ page errorPage="ErrPage.jsp"
         import="java.util.Date, java.sql.*"
         contentType="text/html;charset=gb2312"%>
<jsp:useBean id="pool" scope="application" class="com.PoolBean"/>
   <!--利用JAVABEAN连接数据库-->
<%
String strLoginUser = (String)session.getAttribute("LoginUser");
if (strLoginUser == null || strLoginUser.length() == 0)	
	response.sendRedirect("../Login.jsp");	
%>
<HTML>
<HEAD>
<LINK REL="stylesheet" HREF="../littleproject.css" TYPE="text/css">
<script language="JavaScript" type="text/Javascript">
<!--
function onClickRadio()
{
 var meeting_name="";
 meeting_name=meeting_kind.value;
 if (meeting_name.length >0)
 {
   parent.main.location.replace
     ("manager_meeting_person_right.jsp?num="+meeting_name);
 }
}
-->
</script>
<TITLE>会议人员管理</TITLE>
</HEAD>
<BODY bgcolor=LightBlue>
<%
try{	 
   if (pool.getConnectionSize() == 0)
	{
		pool.initializePool();
	}
	Connection con = null;
	Statement stmt = null;
    ResultSet  rs=null;		
	con = pool.getConnection();
	stmt = con.createStatement(ResultSet.TYPE_SCROLL_INSENSITIVE,
				   ResultSet.CONCUR_READ_ONLY);
	//建立Statement对象, 并设置记录指标类型为可前后移动
	String sql=null;
	sql="SELECT id,num,title FROM meeting order by num desc";	
	rs = stmt.executeQuery(sql);	
%>
<TABLE border=1 bordercolor=RoyalBlue bgcolor=LightBlue width=200>
  <tr>
	<TD bgcolor=LightYellow width=200 align=center>会议主题</TD>
  </tr>
<%
out.println("<TR>");  
out.println("<TD width=200>");
out.println("<select name=meeting_kind size=29 onclick=\"onClickRadio()\" style=\"background-color: LightBlue;border-style: solid; border-width: 0; width:100%;font-size: 12pt\">");
while(rs.next())
{     
   int select_id = rs.getInt("id");
   int select_num = rs.getInt("num");
   String select_title= rs.getString("title");      
   out.println("<option value="+select_num+">" + select_title +"</option>");  
}
 out.println("</select>");
 out.println("</TD>");  
 out.println("</TR>"); 
%>
</TABLE>
<%
	if (rs != null) rs.close();
	pool.releaseConnection(con);
}
catch(Exception e)
{
	System.out.println("Exception: " + e.getMessage());
}
 %>
</BODY>

⌨️ 快捷键说明

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