?? drop.jsp
字號:
<%@ page contentType="text/html; charset=gb2312" language="java" import="java.sql.*" errorPage="" %>
<%
String password="arthemis";//管理員密碼
String mm=null;mm=(String)session.getAttribute("pass");
if(password.equals(mm)){
String id=request.getParameter("id");
if(id==null){out.print("<h3><font color=#FF0000>ERROR!</font></h3>");}else{
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
Connection con=DriverManager.getConnection("jdbc:odbc:numb1");
Statement st=con.createStatement(ResultSet.TYPE_SCROLL_SENSITIVE,ResultSet.CONCUR_UPDATABLE);
String sql="delete from lyb where id="+id;
st.executeUpdate(sql);
st.close();
con.close();
response.sendRedirect("index.jsp");
}
}else{
response.sendRedirect("log.jsp");
}
%>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -