See how JSP implements pagination display (employee management)

Source: Internet
Author: User
Tags getdate

pagination shows a lot of use in actual development, here is a list of employees to display the example, using no paging, pagination (fake pagination and true pagination) to display, with complete code, if you want to learn pagination, this is a good learning material.

1, do not use pagination to display, the code is as follows:

emp_list.jsp:

<%@ page contenttype= "text/html" pageencoding= "GBK"%> <%@ page import= "java.sql.*"%>  

The results are as follows when the page is displayed without paging:

2, the use of false pagination to display, the code is as follows:

emp_list_false.jsp:

<%@ page contenttype= "text/html" pageencoding= "GBK"%> <%@ page import= "java.sql.*"%>  

The effect of displaying with false pagination is as follows:

3, the use of true pagination to display the list of employees, the code is as follows:

emp_list_true.jsp:

<%@ page contenttype= "text/html" pageencoding= "GBK"%> <%@ page import= "java.sql.*"%>  

The results of true pagination display are as follows:



Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.