gistfile1.txt package servlet;import java.io.IOException;import java.io.PrintWriter;import java.util.HashMap;import java.util.List;import java.util.Map;import javax.servlet.ServletException;import javax.servlet.ServletRequest;import javax.s
package servlet; import java.io.IOException; import java.io.PrintWriter; import java.util.HashMap; import java.util.List; import java.util.Map; import javax.servlet.ServletException; import javax.servlet.ServletRequest; import javax.servlet.ServletResponse; import javax.servlet.annotation.WebServlet; import javax.servlet.http.HttpServlet; import com.alibaba.fastjson.JSONObject; import until.DbUtil_IDUS; @WebServlet("/ajax.do") public class Ajax extends HttpServlet{ @Override public void service(ServletRequest req, ServletResponse res) throws ServletException, IOException { //中文乱码 req.setCharacterEncoding("utf-8"); res.setContentType("text/html;charset=utf-8"); PrintWriter out = res.getWriter(); //数据操作对象 DbUtil_IDUS dbs = new DbUtil_IDUS(); //当前页 int currpage = req.getParameter("p")==null ? 1 : Integer.parseInt(req.getParameter("p")); dbs.setPagesize(3); List