Student management system based on BootStrap+JSP (graduation project)

Posted by doc on Mon, 06 Dec 2021 20:19:15 +0100

1. Foreword

The graduation design project I have done is only basic. There are no outstanding functions. The styles of several modules in the background are the same. They are all tables.

2. Overview

The front-end uses the BootStrap framework, and the back-end code is mainly realized by JSP. The main functions include user login, home page, administrator login, student management, student performance, class information, course management, course opening information, details, role management and exit login, When you log in as an administrator, you can add, delete, modify and query the data in the database.

  • Operating environment
    Operating system: Windows 10;
    Development tools: IDEA, Tomcat 8.5, MySQL (Navicat);

3. Screenshot of project operation

  • In the user login interface, enter the user name and password for authentication.

  • On the home page, you can log in as an administrator, make a line chart with ECharts chart, make three tables with ace framework, and store the user name entered during login through session and display it on the home page.

  • Click the administrator login button to enter the administrator login interface, and enter the user name and password for verification.

  • In the background student information management interface, the user name entered during login is also stored through session, and the user name entered during login is displayed on the navigation bar

  • Student management, display the data in the database table, and realize the operation of addition, deletion, modification and query

  • The remaining student scores, class information, course management, course opening information and details are the same as the student management interface.
  • Role management is divided into teacher side and teacher side. Click different buttons to enter different interfaces.

  • Click exit login to jump to the administrator login interface.

4. Partial code

  • User login authentication
public class LoginServlet extends HttpServlet {

    protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {
        super.doPost(req, resp);

    protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
        String username = request.getParameter("username");//Get user name
        String password = request.getParameter("password");//Get password
        UserDao userDao=new UserDao();
            HttpSession session=request.getSession();
            //Log in successfully and enter the main interface
            session.setAttribute("yonghu",username);//Store the current user name in the session
            request.getRequestDispatcher("main.jsp").forward(request,response);//The request is distributed to the main interface, directed to the main interface, and the request and response are imported into the main interface
            //Login failed. Enter the login interface
  • Database connection
public class DB {
    /*Database access process
       1.Load the driver of the database    
       2.Get link to database connector 
       3.Processing access statement statement  
       4.Resultset resultset         
    private static DataSource ds ;
    //Load driver
    private  static String driver="com.mysql.jdbc.Driver";
    private static String url="jdbc:mysql://localhost:3309/two";
    //User name and password
    private static String username="root";
    private static String password="root";
    //Get a link to the database
    public static Connection getConnection(){
        Connection connection=null;
        //Load driver
        try {
            connection= DriverManager.getConnection(url,username,password);
        } catch (Exception e) {
        return connection;
     * Get connection pool object
    public static DataSource getDataSource(){
        return ds;


5. Database structure

  • Database name: two;
  • Database tables: a total of 10 tables (only part of the table contents are written here)


numberListingdata type

t_user :

numberListingdata type


numberListingdata type


numberListingdata type

6. Summary

After learning and mastering the knowledge of java object-oriented, JSP dynamic web page technology, JavaScript programming and HTML5 application development, and the design and implementation of this student information management system, I learned the importance of mastering a programming language. JSP actually embeds Java program fragments and JSP tags into HTML documents. When the client accesses a JSP Web page, the program fragments will be executed and then returned to the standard HTML documents of the client. At the same time, I also have a new understanding and understanding of Java. Java is object-oriented and has the characteristics of encapsulation, inheritance, polymorphism and abstraction, which can improve the efficiency of software development. As a student majoring in software technology, it is very important to learn Java, JSP and other programming languages well. During the design of this system, I also learned the BootStrap front-end development framework. The BootStrap framework is based on HTML, CSS and JavaScript, which can make web development more convenient. The mastery of front-end VUE, element, Ajax, jQuery style, etc. makes my realization of web page layout, style, web page effect, etc. more accurate.

Of course, the student management system has many functions that need to be realized this time, such as authentication code security mechanism during login, login with different identities on the same login page, paging function and so on. These functions haven't been explored in time, and technologies will be added to the project in the future.

Topics: Java Front-end html bootstrap