导航菜单
首页 >  在线报考  > 基于javaweb+mysql的jsp+servlet学校在线报考系统(java+jsp+javascript+servlet+mysql)

基于javaweb+mysql的jsp+servlet学校在线报考系统(java+jsp+javascript+servlet+mysql)

基于javaweb+mysql的jsp+servlet学校在线报考系统(java+jsp+javascript+servlet+mysql)

私信源码获取及调试交流

运行环境

Java≥8、MySQL≥5.7、Tomcat≥8

开发工具

eclipse/idea/myeclipse/sts等均可配置运行

适用

课程设计,大作业,毕业设计,项目练习,学习演示等

功能说明

基于javaweb+mysql的JSP+Servlet学校在线报考系统(java+jsp+javascript+servlet+mysql)

项目介绍

本项目分为管理员、教务人员、招生人员、学生等角色;

管理员角色主要功能包括: 系统状态、阶段定义、管理员维护、数据库管理、查看报名信息、我的登录历史、修改密码、退出系统;

教务人员主要功能包括: 系统状态、查看报名信息、准考证号分配、考场分配、录入成绩、我的登录历史、修改密码、退出系统;

招生人员主要功能包括: 系统状态、阶段设置、招考信息设置、查看报名信息、现场确认、学生密码清零、我的登录历史、修改密码、退出系统;

学生角色主要功能包括: 报考须知、我的报名信息、上传照片、报名表打印、准考证打印、成绩与录取查询、我的登录历史、修改密码、退出系统等;

环境需要

1.运行环境:最好是java jdk 1.8,我们在这个平台上运行的。其他版本理论上也可以。 2.IDE环境:IDEA,Eclipse,Myeclipse都可以。推荐IDEA; 3.tomcat环境:Tomcat 7.x,8.x,9.x版本均可 4.硬件环境:windows 7/8/10 1G内存以上;或者 Mac OS; 5.数据库:MySql 5.7版本; 6.是否Maven项目:否;

技术栈

后端:Servlet 2. 前端:JSP+JavaScript+CSS

使用说明

使用Navicat或者其它工具,在mysql中创建对应名称的数据库,并导入项目的sql文件; 2. 使用IDEA/Eclipse/MyEclipse导入项目,Eclipse/MyEclipse导入时,若为maven项目请选择maven; 若为maven项目,导入成功后请执行maven clean;maven install命令,然后运行; 3. 将项目中WebRoot/META-INF/context.xml配置文件中的数据库配置改为自己的配置; 4. 运行项目,学生角色使用http://localhost:8080/bkxt/index.jsp进行登录 学生账号/密码:zjfhit/123456 管理员登录:http://localhost:8080/bkxt/manage.jsp 管理员账号/密码:manager/123456 教务人员账号/密码:jiaowu/123456 招生人员账号/密码:zhaoban/123456request.removeAttribute("newpass"); request.removeAttribute("confirmpass"); request.removeAttribute("code"); session.removeAttribute("adminuser"); request.setAttribute("adminLoginMess", "* 密码修改成功,请重新登录!"); request.getRequestDispatcher("/manage.jsp").forward(request, response); } else { request.setAttribute("passModifyMess", "* 密码修改失败!"); request.getRequestDispatcher("/admin/pass.jsp").forward(request, response);} }} } private String validateForm(String oldpass,String newpass,String confirmpass,String code){if (oldpass == null || !oldpass.matches("\\w{6,20}")){ return "* 旧密码错误!";}else if (newpass == null || !newpass.matches("\\w{6,20}")) { return "* 新密码不合法!";}else if (!newpass.equals(confirmpass)) { return "* 两次输入的新密码不一致,请重新输入!";}else if (code == null || !code.matches("\\d{4}")) { return "* 验证码错误!";}return ""; } /*** Initialization of the servlet. ** @throws ServletException if an error occurs*/ public void init() throws ServletException {// Put your code here }} public class JAdminRoom extends HttpServlet {/** * Constructor of the object. */public JAdminRoom() {super();}/** * Destruction of the servlet. */public void destroy() {super.destroy(); // Just puts "destroy" string in log// Put your code here}/** * The doGet method of the servlet. * * This method is called when a form has its tag value method equals to get. * * @param request *the request send by the client to the server * @param response *the response send by the server to the client * @throws ServletException * if an error occurred * @throws IOException * if an error occurred */public void doGet(HttpServletRequest request, HttpServletResponse response)throws ServletException, IOException {response.setContentType("text/html");this.doPost(request, response);}/**public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {this.doPost(request, response); } /*** The doPost method of the servlet. ** This method is called when a form has its tag value method equals to post.* * @param request the request send by the client to the server* @param response the response send by the server to the client* @throws ServletException if an error occurred* @throws IOException if an error occurred*/ public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {response.setContentType("text/html");int pageSize = request.getParameter("pageSize") == null ? 5 : Integer.parseInt(request.getParameter("pageSize").toString());int pageNo = request.getParameter("pageNo") == null ? 1 : Integer.parseInt(request.getParameter("pageNo").toString());HttpSession session = request.getSession();RecordDao recordDao = new RecordDaoImpl();System.out.println(pageNo);PageModel pm = recordDao.pageByLogname(pageSize, pageNo);pm.setPageNav(request.getRequestURI());File file = (File)request.getAttribute("file1");if(file != null){try {GradeDaoImpl gradeImpl = new GradeDaoImpl();Workbook workbook = Workbook.getWorkbook(file);Sheet sheet = workbook.getSheet(0);for(int row = 2;row

相关推荐: