📄 jingpinupdate.jsp
字号:
<%@ page contentType="text/html;charset=GBK"%>
<%
if(session.getAttribute("midentity")==null)
{
// request.setAttribute("result","您没有权力进入此页");
// getServletContext().getRequestDispatcher("display.jsp").forward(request,response);
response.sendRedirect("FlowerIndex.jsp");
}
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=GBK">
<title>精品信息更新</title>
<link href="css/jdeveloper.css" rel="stylesheet" media="screen"/>
</head>
<body>
<table width="760" border="0" align="center">
<tr>
<td><h1 align="center">精品信息更新</h1>
<form action="jingpin" method="post">
<table width="80%" border="1" align="center" cellspacing="1" cellpadding="2">
<%
Connection con1=null;
PreparedStatement pstmt1=null;
ResultSet rs1=null;
String jpid1=request.getParameter("jpid1");
con1=DBConnect.getConnection();
pstmt1=con1.prepareStatement("select * from jingpin where jpid=?");
pstmt1.setString(1,jpid1);
rs1=pstmt1.executeQuery();
while(rs1.next())
{
%>
<tr>
<td>精品编号:</td>
<td><input type="text" name="jpid" value="<%=rs1.getString(1)%>" readonly></td>
</tr>
<tr>
<td>商品编号:</td>
<td><select name="goodsid">
<%
Connection con=null;
PreparedStatement pstmt=null;
ResultSet rs=null;
con=DBConnect.getConnection();
pstmt=con.prepareStatement("select * from goodsinfo");
rs=pstmt.executeQuery();
while(rs.next())
{
String aa=rs.getString(1);
%>
<option value="<%=aa%>">
<%=aa%>
</option>
<%
}
rs.close();
pstmt.close();
con.close();
%>
</select></td>
</tr>
<%
}
rs1.close();
pstmt1.close();
con1.close();
%>
<tr>
<td>系统提示:</td>
<td>
<%
String result="请注意系统提示";
if(request.getAttribute("result")!=null)
{
result=request.getAttribute("result").toString();
}
%>
<font color="red"><%=result%></font>
</td>
</tr>
<tr>
<td> </td>
<td><input type="submit" name="Submit" value="提交">
<input type="reset" name="Submit2" value="重置">
<a href="ManagerMain.jsp">返回管理员主页</a>
<input type="hidden" name="action" value="update"/></td>
</tr>
</table>
<P>
<%@ page import="java.sql.*"%>
<%@ page import="Flower.model.DBConnect"%>
</P>
<div align="center"></div>
</form> <p align="center"> </p> <p> </p>
<p> </p>
<p> </p>
<p> </p></td>
</tr>
</table>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -