jsp5 include forward param

C436FCDCEB6B2FE50D576CBFA44AE681.png007615AF07CE7F94A058DD5149066B88.png
date.jsp
  1. <%@page import="java.text.SimpleDateFormat"%>
  2. <%@ page language="java" import="java.util.*" contentType="text/html; charset=UTF-8"%>
  3. <%
  4. Date d=new Date();
  5. SimpleDateFormat sdf=new SimpleDateFormat("yyyy年MM月dd日");
  6. String s=sdf.format(d);
  7. out.println(s);
  8. %>
Includecommand.jsp
  1. <body>
  2. <h1>Include指令</h1><hr>
  3. <%@include file="date.jsp" %>
  4. </body>

  5. 70DFFF6B30CB691AC1BFD8821EDCB130.png

    Include_Action.jsp
    <h1>Include动作</h1><hr>

    <jsp:include page="date.jsp"flush="false"

    454E9D847EF514845D9C435191503DB1.png
    Screenshot_2016-05-04-18-17-00-165.pngScreenshot_2016-05-04-18-19-32-866.pngScreenshot_2016-05-04-18-20-41-468.png




原文地址:https://www.cnblogs.com/liuruimiku/p/5459388.html