导学

在之前的学习中,我们发现虽然可以在Jsp中使用Java语言,但是HTML和Java的结合好像不是那么紧密,而且操作HTML元素好像也不是那么方便。那么有没有一种简单的方式,来获取值并操作HTML元素呢?

EL表达式

EL表达式是一种非常简单的数据表达方式,EL(Expression Language)表达式语言的出现就是为了简化JSP的输出。在早期的Jsp中,没有EL表达式,所有的程序都要使用out对象来一行行的输出。
语法:

  1. ${表达式}

实例:

  1. public class Student {
  2. private String name;
  3. private String mobile;
  4. public String getName() {
  5. return name;
  6. }
  7. public void setName(String name) {
  8. this.name = name;
  9. }
  10. public String getMobile() {
  11. return mobile;
  12. }
  13. public void setMobile(String mobile) {
  14. this.mobile = mobile;
  15. }
  16. public String toString() {
  17. return name + ":" + mobile;
  18. }
  19. }
  1. @WebServlet("/info")
  2. public class StudentServlet extends HttpServlet {
  3. private static final long serialVersionUID = 1L;
  4. public StudentServlet() {
  5. super();
  6. }
  7. protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
  8. Student stu = new Student();
  9. stu.setName("子墨");
  10. stu.setMobile(null);
  11. String grade = "A";
  12. request.setAttribute("grade", grade);
  13. request.setAttribute("student", stu);
  14. request.getRequestDispatcher("/info.jsp").forward(request, response);
  15. }
  16. }
  1. <%@ page language="java" contentType="text/html; charset=UTF-8"
  2. pageEncoding="UTF-8" import = "com.dodoke.el.Student"%>
  3. <!DOCTYPE html>
  4. <html>
  5. <head>
  6. <meta charset="UTF-8">
  7. <title>Insert title here</title>
  8. </head>
  9. <body>
  10. <%
  11. Student stu = (Student)request.getAttribute("student");
  12. String grade = (String)request.getAttribute("grade");
  13. out.println("<h1>姓名:" + stu.getName() + "</h1>");
  14. out.println("<h2>手机:" + stu.getMobile() + "</h2>");
  15. out.println("<h2>评级:" + grade + "</h2>");
  16. %>
  17. </body>
  18. </html>

EL表达式版

  1. <%@ page language="java" contentType="text/html; charset=UTF-8"
  2. pageEncoding="UTF-8"%>
  3. <!DOCTYPE html>
  4. <html>
  5. <head>
  6. <meta charset="UTF-8">
  7. <title>Insert title here</title>
  8. </head>
  9. <body>
  10. <h1>姓名:${requestScope.student.name }</h1>
  11. <h2>手机:${requestScope.student.mobile }</h2>
  12. <h2>评级:${requestScope.grade }</h2>
  13. </body>
  14. </html>

通过以上的例子,我们可以看出EL表达式的应用非常简单,而且还不需要导入要使用的类,下面我们就来看看EL表达式的使用细节。

EL的作用域对象

EL表达式包含四种不同的作用域:

  • pageScope:从当前页面取值
  • requestScope:从当前请求中获取属性值
  • sessionScope:从当前会话中获取属性值
  • applicationScope:从当前应用获取全局属性值

这四种作用域,作用范围从小到大,而且这四种作用域也对应了我们四种取值范围。当我们忽略书写这四种作用域时,el表达式将按作用域从小到大的顺序依次尝试获取。

  1. @WebServlet("/info")
  2. public class StudentServlet extends HttpServlet {
  3. private static final long serialVersionUID = 1L;
  4. public StudentServlet() {
  5. super();
  6. }
  7. protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
  8. Student stu = new Student();
  9. stu.setName("子墨");
  10. stu.setMobile(null);
  11. String grade = "A";
  12. HttpSession session = request.getSession();
  13. session.setAttribute("grade", grade);
  14. session.setAttribute("student", stu);
  15. //request.setAttribute("grade", grade);
  16. //request.setAttribute("student", stu);
  17. request.getRequestDispatcher("/info.jsp").forward(request, response);
  18. }
  19. }
  1. <%@ page language="java" contentType="text/html; charset=UTF-8"
  2. pageEncoding="UTF-8"%>
  3. <!DOCTYPE html>
  4. <html>
  5. <head>
  6. <meta charset="UTF-8">
  7. <title>Insert title here</title>
  8. </head>
  9. <body>
  10. <h1>姓名:${sessionScope.student.name }</h1>
  11. <h2>手机:${sessionScope.student.mobile }</h2>
  12. <h2>评级:${sessionScope.grade }</h2>
  13. </body>
  14. </html>

问:代码修改为这样以后该如何,得到的结果是多少?

  1. protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
  2. String teacher = request.getParameter("teacher");//获取在地址栏向服务器传入的参数?teacher=sammy
  3. Student stu = new Student();
  4. stu.setName("子墨");
  5. stu.setMobile(null);
  6. String grade = "A";
  7. request.setAttribute("grade","B");
  8. request.getServletContext().setAttribute("grade","C");
  9. HttpSession session = request.getSession();
  10. session.setAttribute("grade", grade);
  11. session.setAttribute("student", stu);
  12. //request.setAttribute("grade", grade);
  13. //request.setAttribute("student", stu);
  14. request.getRequestDispatcher("/info.jsp").forward(request, response);
  15. }

EL表达式输出

语法:

  1. ${[作用域].属性名.[子属性名]}

el表达式支持将运算结果输出,也支持绝大多数对象的输出,本质是执行toString方法,也就是我们可以尝试重写toString方法,输出对象的信息。
image.png
5.JSTL与EL表达式 - 图2

输出参数

要求:查找并总结getParameter()方法和getAttribute()方法的区别
在Servlet中我们可以通过getParameter()方法来实现获取前端浏览器的参数,那么如何使用el表达式来接收其他页面传递的参数呢?
EL表达式内置param对象来简化参数的输出,它的语法:

  1. ${param.参数名}
  1. <%@ page language="java" contentType="text/html; charset=UTF-8"
  2. pageEncoding="UTF-8"%>
  3. <!DOCTYPE html>
  4. <html>
  5. <head>
  6. <meta charset="UTF-8">
  7. <title>Insert title here</title>
  8. </head>
  9. <body>
  10. <h1>姓名:${sessionScope.student.name }</h1>
  11. <h2>手机:${sessionScope.student.mobile }</h2>
  12. <h2>${param.teacher}</h2>//输出地址栏输入的参数数据teacher=sammy
  13. //getParameter("teacher")的简化形式
  14. <h2>评级:${sessionScope.grade }</h2>
  15. </body>
  16. </html>

JSTL标签库

  • JSTL(JSP Standard Tag Library),JSP标准标签库
  • JSTL用于简化JSP开发,提高代码的可读性和可维护性
  • JSTL由SUN(Oracle)定义规范,由Apache Tomcat团队实现
    JSTL可以帮助我们实现表格的循环,判断,数据的迭代等功能。

    JSTL下载与安装

    el表达式,不需要下载任何的Jar包,这是因为现版本的jsp内置el表达式的实现,但是JSTL就需要下载Jar包并安装到项目中。
    下载地址:http://tomcat.apache.org/
    JSTL 1.2.5组件介绍:
    5.JSTL与EL表达式 - 图3
    需要下载的是一个spec的包,一个是impl包,剩下的包,el的包是为了支持el表达式,现在el已经内置标签库了,所以不需要下载导入即可使用。第四个jar包是为了兼容1.0以下的包而使用的 我们现在使用的是1.2.5因此无需引入。
    5.JSTL与EL表达式 - 图4
    5.JSTL与EL表达式 - 图5
    安装JSTL
    JSTL的两种安装方式:
  1. 将Jar文件复制到工程的/WEB-INF/lib目录下(对单体项目进行设置-推荐)
  2. 将Jar文件复制到Tomcat安装目录的lib目录(全局设置)

    JSTL的标签库

    JSTL按功能划分,可分为五类标签库:
    5.JSTL与EL表达式 - 图6
    除了头两种,剩下的已经不使用了,因为在Java中提供了更好的支持。
    引用JSTL核心库
    image.png
    核心标签库,提供了JSTL的基础功能,引用时需要在页面上引入该核心库
    1. <%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>

    JSTL判断标签

    JSTL核心库提供了两组判断的标签:
  • <c:if>用于单分支判断
  • <c:choose><c:when><c:otherwise>用于多分支判断

    1. @WebServlet("/jstl")
    2. public class JstlServlet extends HttpServlet {
    3. private static final long serialVersionUID = 1L;
    4. public JstlServlet() {
    5. super();
    6. }
    7. protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
    8. request.setAttribute("score", 58);
    9. request.setAttribute("grade", "B");
    10. request.getRequestDispatcher("/core.jsp").forward(request, response);
    11. }
    12. }
    1. <%@ page language="java" contentType="text/html; charset=UTF-8"
    2. pageEncoding="UTF-8"%>
    3. <!-- Java或者JSP文件中输入 Alt + / 可出现智能提示 -->
    4. <!-- uri指定使用哪个标签库,prefix指定使用时的前缀,prefix属性的值是可以改变的,只不过我们一般习惯用c表示。 -->
    5. <%@ taglib uri = "http://java.sun.com/jsp/jstl/core" prefix = "c" %>
    6. <!DOCTYPE html>
    7. <html>
    8. <head>
    9. <meta charset="UTF-8">
    10. <title>Insert title here</title>
    11. </head>
    12. <body>
    13. <h1>${requestScope.score}</h1>
    14. <!-- 简单判断:test属性中填写truefalse,用于决定c:if中的HTML语句是否输出 -->
    15. <c:if test = "${score >= 60 }">
    16. <h1 style = "color:green">恭喜,你已通过测试</h1>
    17. </c:if>
    18. <c:if test = "${score < 60 }">
    19. <h1 style = "color:red">对不起,再接再厉</h1>
    20. </c:if>
    21. <!-- 复杂判断:choose when otherwise -->
    22. ${grade }
    23. <c:choose>
    24. <!-- 注意单引号,在JSTL中可以使用等号进行字符串的判断 -->
    25. <c:when test="${grade == 'A'}">
    26. <h2>你很优秀</h2>
    27. </c:when>
    28. <c:when test="${grade == 'B' }">
    29. <h2>不错呦</h2>
    30. </c:when>
    31. <c:when test="${grade == 'C' }">
    32. <h2>水平一般,需要提高</h2>
    33. </c:when>
    34. <c:when test = "${grade == 'D'}">
    35. <h2>需要努力啦,不要气馁</h2>
    36. </c:when>
    37. <c:otherwise>
    38. <h2>一切随缘吧</h2>
    39. </c:otherwise>
    40. </c:choose>
    41. </body>
    42. </html>

    JSTL遍历标签

    <c:forEach>标签用于遍历集合(Collection)中的每一个对象。
    image.png ```java public class Company { private String cname; private String url;

    public Company(String cname , String url) {

    1. this.cname = cname;
    2. this.url = url;

    }

    public String getCname() {

    1. return cname;

    } public void setCname(String cname) {

    1. this.cname = cname;

    } public String getUrl() {

    1. return url;

    } public void setUrl(String url) {

    1. this.url = url;

    }

}

  1. ```java
  2. @WebServlet("/jstl")
  3. public class JstlServlet extends HttpServlet {
  4. private static final long serialVersionUID = 1L;
  5. public JstlServlet() {
  6. super();
  7. }
  8. protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
  9. request.setAttribute("score", 58);
  10. request.setAttribute("grade", "B");
  11. List list = new ArrayList();
  12. list.add(new Company("腾讯" , "www.tencent.com"));
  13. list.add(new Company("百度" , "www.baidu.com"));
  14. list.add(new Company("渡课网" , "www.dodoke.com"));
  15. request.setAttribute("companys", list);
  16. request.getRequestDispatcher("/core.jsp").forward(request, response);
  17. }
  18. }
  1. <%@ page language="java" contentType="text/html; charset=UTF-8"
  2. pageEncoding="UTF-8"%>
  3. <!-- Java或者JSP文件中输入 Alt + / 可出现智能提示 -->
  4. <!-- uri指定使用哪个标签库,prefix指定使用时的前缀,prefix属性的值是可以改变的,只不过我们一般习惯用c表示。 -->
  5. <%@ taglib uri = "http://java.sun.com/jsp/jstl/core" prefix = "c" %>
  6. <!DOCTYPE html>
  7. <html>
  8. <head>
  9. <meta charset="UTF-8">
  10. <title>Insert title here</title>
  11. </head>
  12. <body>
  13. <h1>${requestScope.score}</h1>
  14. <!-- test属性中填写truefalse,用于决定c:if中的HTML语句是否输出 -->
  15. <c:if test = "${score >= 60 }">
  16. <h1 style = "color:green">恭喜,你已通过测试</h1>
  17. </c:if>
  18. <c:if test = "${score < 60 }">
  19. <h1 style = "color:red">对不起,再接再厉</h1>
  20. </c:if>
  21. <!-- choose when otherwise -->
  22. ${grade }
  23. <c:choose>
  24. <!-- 注意单引号,在JSTL中可以使用等号进行字符串的判断 -->
  25. <c:when test="${grade == 'A'}">
  26. <h2>你很优秀</h2>
  27. </c:when>
  28. <c:when test="${grade == 'B' }">
  29. <h2>不错呦</h2>
  30. </c:when>
  31. <c:when test="${grade == 'C' }">
  32. <h2>水平一般,需要提高</h2>
  33. </c:when>
  34. <c:when test = "${grade == 'D'}">
  35. <h2>需要努力啦,不要气馁</h2>
  36. </c:when>
  37. <c:otherwise>
  38. <h2>一切随缘吧</h2>
  39. </c:otherwise>
  40. </c:choose>
  41. <!-- forEach标签用于遍历集合
  42. List companys = (List)request.getAttribute("companys")
  43. for(Company c : companys){
  44. out.print("...")
  45. }
  46. items 代表循环的数据源
  47. var = c 指的是每一次循环得到的变量都会赋值给c
  48. idx = index 循环的索引,但是索引值还是需要通过以下的index属性来获取
  49. idx.index属性代表循环的索引值(0开始)
  50. -->
  51. <c:forEach varStatus="idx" items = "${requestScope.companys }" var = "c">
  52. <h2 style="color:green">${idx.index + 1}-${c.cname }-${c.url }</h2>
  53. </c:forEach>
  54. </body>
  55. </html>

fmt格式化标签库

fmt格式化标签库可以使数据按照我们设想的格式进行输出。
它的引用地址为:

  1. http://java.sun.com/jsp/jstl/fmt

在这个标签库中,主要学习两种格式化语句:
格式化日期标签
<fmt:formateDate value="" pattern="">
格式化数字标签
<fmt:formatNumber value="" pattern="">

  1. <%@ page language="java" contentType="text/html; charset=UTF-8"
  2. pageEncoding="UTF-8"%>
  3. <%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
  4. <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
  5. <!DOCTYPE html>
  6. <html>
  7. <head>
  8. <meta charset="UTF-8">
  9. <title>Insert title here</title>
  10. </head>
  11. <body>
  12. <%
  13. //就在当前页面设置数据源,不再创建servlet了
  14. request.setAttribute("amt", 1987654.326);
  15. request.setAttribute("now", new java.util.Date());
  16. request.setAttribute("html", "<a href='index.html'>index</a>");
  17. request.setAttribute("nothing", null);
  18. %>
  19. <h2>${now }</h2>
  20. <!--
  21. formatDate pattern
  22. yyyy - 四位年
  23. MM - 两位月
  24. dd - 两位日
  25. HH - 24小时制
  26. hh - 12小时制
  27. mm - 分钟
  28. ss - 秒数
  29. SSS - 毫秒
  30. -->
  31. <h2>
  32. <!-- value指原始的数据值,pattern表示转换的格式 -->
  33. <fmt:formatDate value="${requestScope.now }" pattern="yyyy年MM月dd日 HH时mm分ss秒 SSS毫秒" />
  34. </h2>
  35. <h2>${amt }</h2>
  36. <h2>¥<fmt:formatNumber value = "${amt }" pattern="0,000.00"></fmt:formatNumber>元</h2>
  37. <!-- 设置输出方式 -->
  38. <h2>null默认值:<c:out value="${nothing }" default="无"></c:out> </h2>
  39. <!-- 设置输出时是否转义 -->
  40. <h2><c:out value="${ html}" escapeXml="true"></c:out></h2>
  41. </body>
  42. </html>

综合训练

通常在进行实际项目的开发时,前端工程师会发送给我们一个静态的页面,而我们要做的就是将这样的静态页面变为动态页面。
静态演示Demo下载地址:链接: https://pan.baidu.com/s/1HFMuCGeg5tox-1MWzGs_vQ 提取码: 2j2z
实例:

  1. public class Employee {
  2. private Integer empno;
  3. private String ename;
  4. private String department;
  5. private String job;
  6. private Float salary;
  7. public Employee(Integer empno, String ename, String department, String job, Float salary) {
  8. super();
  9. this.empno = empno;
  10. this.ename = ename;
  11. this.department = department;
  12. this.job = job;
  13. this.salary = salary;
  14. }
  15. public Integer getEmpno() {
  16. return empno;
  17. }
  18. public void setEmpno(Integer empno) {
  19. this.empno = empno;
  20. }
  21. public String getEname() {
  22. return ename;
  23. }
  24. public void setEname(String ename) {
  25. this.ename = ename;
  26. }
  27. public String getDepartment() {
  28. return department;
  29. }
  30. public void setDepartment(String department) {
  31. this.department = department;
  32. }
  33. public String getJob() {
  34. return job;
  35. }
  36. public void setJob(String job) {
  37. this.job = job;
  38. }
  39. public Float getSalary() {
  40. return salary;
  41. }
  42. public void setSalary(Float salary) {
  43. this.salary = salary;
  44. }
  45. }
  1. @WebServlet("/list")
  2. public class ListServlet extends HttpServlet {
  3. private static final long serialVersionUID = 1L;
  4. public ListServlet() {
  5. super();
  6. }
  7. protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
  8. ServletContext context = request.getServletContext();
  9. if(context.getAttribute("employees") == null) {
  10. List list = new ArrayList();
  11. Employee emp = new Employee(7731 , "刘志敏" , "市场部" , "客户代表" , 10000f);
  12. list.add(emp);
  13. list.add(new Employee(8871 , "张倩" , "研发部" , "运维工程师" , 8000f));
  14. context.setAttribute("employees", list);
  15. }
  16. request.getRequestDispatcher("/employee.jsp").forward(request, response);
  17. }
  18. }
  1. <%@ page contentType="text/html;charset=utf-8"%>
  2. <%@ taglib uri = "http://java.sun.com/jsp/jstl/core" prefix = "c" %>
  3. <%@ taglib uri = "http://java.sun.com/jsp/jstl/fmt" prefix = "fmt" %>
  4. <!DOCTYPE html>
  5. <html>
  6. <head>
  7. <meta charset="UTF-8">
  8. <meta name="viewport" content="width=device-width,initial-scale=1">
  9. <title>员工列表</title>
  10. <link href="css/bootstrap.css" type="text/css" rel="stylesheet"></link>
  11. <script type="text/javascript" src="js/jquery-1.11.1.min.js"></script>
  12. <script type="text/javascript" src="js/bootstrap.js"></script>
  13. <style type="text/css">
  14. .pagination {
  15. margin: 0px
  16. }
  17. .pagination > li > a, .pagination > li > span {
  18. margin: 0 5px;
  19. border: 1px solid #dddddd;
  20. }
  21. .glyphicon {
  22. margin-right: 3px;
  23. }
  24. .form-control[readonly] {
  25. cursor: pointer;
  26. background-color: white;
  27. }
  28. #dlgPhoto .modal-body{
  29. text-align: center;
  30. }
  31. .preview{
  32. max-width: 500px;
  33. }
  34. </style>
  35. <script>
  36. $(function () {
  37. $("#btnAdd").click(function () {
  38. $('#dlgForm').modal()
  39. });
  40. })
  41. </script>
  42. </head>
  43. <body>
  44. <div class="container">
  45. <div class="row">
  46. <h1 style="text-align: center">dodoke员工信息表</h1>
  47. <div class="panel panel-default">
  48. <div class="clearfix panel-heading ">
  49. <div class="input-group" style="width: 500px;">
  50. <button class="btn btn-primary" id="btnAdd"><span class="glyphicon glyphicon-zoom-in"></span>新增
  51. </button>
  52. </div>
  53. </div>
  54. <table class="table table-bordered table-hover">
  55. <thead>
  56. <tr>
  57. <th>序号</th>
  58. <th>员工编号</th>
  59. <th>姓名</th>
  60. <th>部门</th>
  61. <th>职务</th>
  62. <th>工资</th>
  63. <th>&nbsp;</th>
  64. </tr>
  65. </thead>
  66. <tbody>
  67. <c:forEach items = "${applicationScope.employees}" var = "emp" varStatus="idx" >
  68. <tr>
  69. <td>${idx.index + 1}</td>
  70. <td>${emp.empno }</td>
  71. <td>${emp.ename }</td>
  72. <td>${emp.department }</td>
  73. <td>${emp.job }</td>
  74. <td style="color: red;font-weight: bold"><fmt:formatNumber value = "${emp.salary }" pattern="0,000.00" ></fmt:formatNumber></td>
  75. </tr>
  76. </c:forEach>
  77. </tbody>
  78. </table>
  79. </div>
  80. </div>
  81. </div>
  82. <!-- 表单 -->
  83. <div class="modal fade" tabindex="-1" role="dialog" id="dlgForm">
  84. <div class="modal-dialog" role="document">
  85. <div class="modal-content">
  86. <div class="modal-header">
  87. <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span>
  88. </button>
  89. <h4 class="modal-title">新增员工</h4>
  90. </div>
  91. <div class="modal-body">
  92. <form action="/employee/create" method="post" >
  93. <div class="form-group">
  94. <label >员工编号</label>
  95. <input type="text" name="empno" class="form-control" id="empno" placeholder="请输入员工编号">
  96. </div>
  97. <div class="form-group">
  98. <label >员工姓名</label>
  99. <input type="text" name="ename" class="form-control" id="ename" placeholder="请输入员工姓名">
  100. </div>
  101. <div class="form-group">
  102. <label>部门</label>
  103. <select id="dname" name="department" class="form-control">
  104. <option selected="selected">请选择部门</option>
  105. <option value="市场部">市场部</option>
  106. <option value="研发部">研发部</option>
  107. <option value="后勤部">后勤部</option>
  108. </select>
  109. </div>
  110. <div class="form-group">
  111. <label>职务</label>
  112. <input type="text" name="job" class="form-control" id="sal" placeholder="请输入职务">
  113. </div>
  114. <div class="form-group">
  115. <label >工资</label>
  116. <input type="text" name="salary" class="form-control" id="sal" placeholder="请输入工资">
  117. </div>
  118. <div class="form-group" style="text-align: center;">
  119. <button type="submit" class="btn btn-primary">保存</button>
  120. </div>
  121. </form>
  122. </div>
  123. </div><!-- /.modal-content -->
  124. </div><!-- /.modal-dialog -->
  125. </div><!-- /.modal -->
  126. </body>
  127. </html>
  1. @WebServlet("/create")
  2. public class CreateServlet extends HttpServlet {
  3. private static final long serialVersionUID = 1L;
  4. public CreateServlet() {
  5. super();
  6. }
  7. protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
  8. request.setCharacterEncoding("UTF-8");
  9. String empno = request.getParameter("empno");
  10. String ename = request.getParameter("ename");
  11. String department = request.getParameter("department");
  12. String job = request.getParameter("job");
  13. String salary = request.getParameter("salary");
  14. System.out.println(empno);
  15. Employee emp = new Employee(Integer.parseInt(empno) , ename , department , job , Float.parseFloat(salary));
  16. ServletContext context = request.getServletContext();
  17. List employees = (List)context.getAttribute("employees");
  18. employees.add(emp);
  19. context.setAttribute("employees", employees);
  20. request.getRequestDispatcher("/employee.jsp").forward(request, response);
  21. }
  22. }