PIPIONE
把import javax.mail.Session;这行代码删了修改public static boolean checkuser(String username,String password)方法为public static boolean checkuser(String username,String password,HttpSession session)代码Session.setAttribute("username","rs.getString(username)");修改为session.setAttribute("username","rs.getString(username)");在调用checkuser方法时,在最后记得传入request.getSession()参数