JAVAEE-based-parking-manage.../tingchechang/WebContent/admin/delete.jsp

68 lines
2.3 KiB
Plaintext

<%@ page language="java" contentType="text/html; charset=GB18030"
pageEncoding="GB18030" import="java.sql.*"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<jsp:useBean id="delete" class="com.DB" scope="page" />
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=GB18030">
<title>Insert title here</title>
</head>
<body>
<%
String j=request.getParameter("j");
int pp=Integer.parseInt(j);
if (pp==1) {
String id=request.getParameter("id");
String sqlo="delete from reg where id='"+id+"'";
delete.executeUpdate(sqlo);
out.println("<script lanage='javascript'>alert('删除成功!!');window.location.href='siji_list.jsp';</script>");
}
if (pp==2) {
String id=request.getParameter("id");
String sqlo="delete from reg where id='"+id+"'";
delete.executeUpdate(sqlo);
out.println("<script lanage='javascript'>alert('删除成功!!');window.location.href='ck_list.jsp';</script>");
}
if (pp==3) {
String id=request.getParameter("id");
String sqlo="delete from jifei where id='"+id+"'";
delete.executeUpdate(sqlo);
out.println("<script lanage='javascript'>alert('删除成功!!');window.location.href='kemu_mg.jsp';</script>");
}
if (pp==4) {
String id=request.getParameter("id");
String sqlo="delete from gg where id='"+id+"'";
delete.executeUpdate(sqlo);
out.println("<script lanage='javascript'>alert('删除成功!!');window.location.href='kecheng_mg.jsp';</script>");
}
if (pp==5) {
String id=request.getParameter("id");
String sqlo="delete from feiyong where id='"+id+"'";
delete.executeUpdate(sqlo);
out.println("<script lanage='javascript'>alert('删除成功!!');window.location.href='shoufei_list.jsp';</script>");
}
if (pp==6) {
String id=request.getParameter("id");
String sqlo="delete from dingdan where id='"+id+"'";
delete.executeUpdate(sqlo);
out.println("<script lanage='javascript'>alert('删除成功!!');window.location.href='../chengke/dingdan_quxiao.jsp';</script>");
}
if (pp==7) {
String id=request.getParameter("id");
String sqlo="delete from jiaoliu where id='"+id+"'";
delete.executeUpdate(sqlo);
out.println("<script lanage='javascript'>alert('删除成功!!');window.location.href='../chengke/jiaoliu_gl.jsp';</script>");
}
%>
</body>
</html>