摘要: 缺点:唯一性判断要求采用异步(jQuery Ajax)的方式进行实现(不是用该方法实现的) 使用的是servlet2.5 package dao; import java.sql.Connection; import java.sql.PreparedStatement; import java.s 阅读全文
posted @ 2020-06-04 20:36 王春鹏 阅读(888) 评论(1) 推荐(0)
摘要: public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { doPost(request, response); } public 阅读全文
posted @ 2020-05-22 14:31 王春鹏 阅读(172) 评论(0) 推荐(0)
摘要: // 注册功能 public boolean register(Users user) { Connection con = null; PreparedStatement ps = null; try { con = getConnection(); String sql = "insert in 阅读全文
posted @ 2020-05-15 14:02 王春鹏 阅读(181) 评论(0) 推荐(0)
摘要: <body> <% request.setCharacterEncoding("utf-8"); String uuname = (String) session.getAttribute("uname"); session.setAttribute("uuname", uuname); Conne 阅读全文
posted @ 2020-05-08 16:26 王春鹏 阅读(184) 评论(0) 推荐(0)
摘要: <body> <form action="dologin.jsp" method="post"> 用户名:<input type="text" name="uname" value="kitty" /><Br> 密码 :<input type="password" name="upwd" value 阅读全文
posted @ 2020-04-27 13:43 王春鹏 阅读(262) 评论(0) 推荐(0)
摘要: <body> <form action="tianjia.jsp"> <table> <tr> <td>序号:</td> <td><input type="text" name="id"></td> </tr> <tr> <td>性别:</td> <td><input type="text" nam 阅读全文
posted @ 2020-04-19 16:55 王春鹏 阅读(226) 评论(0) 推荐(0)
摘要: public class JDBCUtils { // 获取对象方法 public static Connection getcon() throws Exception { // 注册驱动 Class.forName("com.mysql.jdbc.Driver"); // 获取连接 Connec 阅读全文
posted @ 2020-04-17 20:56 王春鹏 阅读(160) 评论(0) 推荐(0)
摘要: <%@ page language="java" import="java.util.*" pageEncoding="utf-8"%> <% String path = request.getContextPath(); String basePath = request.getScheme()+ 阅读全文
posted @ 2020-04-10 11:58 王春鹏 阅读(186) 评论(0) 推荐(0)
摘要: <body> <h2 class="a">欢迎来到新闻发布系统</h2> <form action="denglu.jsp" > <button >登录</button></form>&nbsp;&nbsp; <form action="zhuce.jsp" class="b"> <button>注 阅读全文
posted @ 2020-04-04 20:59 王春鹏 阅读(117) 评论(0) 推荐(0)
摘要: <%@ page language="java" import="java.util.*" pageEncoding="utf-8"%> <% String path = request.getContextPath(); String basePath = request.getScheme()+ 阅读全文
posted @ 2020-03-27 14:42 王春鹏 阅读(158) 评论(0) 推荐(0)