-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmember_control.jsp
39 lines (31 loc) · 1.05 KB
/
member_control.jsp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<%@ page language="java" contentType="text/html; charset=EUC-KR" errorPage="member_error.jsp"
pageEncoding="EUC-KR" import="book.*, java.util.ArrayList"%>
<% request.setCharacterEncoding("UTF-8"); %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>control 페이지</title>
</head>
<body>
<jsp:useBean id="mb" class="book.MemberBean" scope="session"/>
<jsp:useBean id="member" class="book.Member" scope="session"/>
<%
String action = request.getParameter("action");
if(action.equals("delete")) {
String userid= (String)session.getAttribute("username");
if(mb.deleteDB(userid)) {
response.sendRedirect("login_form.html");
}
else
throw new Exception("DB 삭제오류");
}
else if(action.equals("login")) {
response.sendRedirect("login_form.html");
}
else {
out.println("<script>alert('action 파라미터를 확인해 주세요!!!')</script>");
}
%>
</body>
</html>