Write
a JAVA JSP Program which uses jsp: include and jsp: forward action to display a
Web page.
jsp:forward action tag with parameter
// index.jsp
<html>
<body>
<h2>this is index
page</h2>
<jsp:forward page="printdate.jsp "
>
<jsp:param name="name"
value="javatpoint.com" />
</jsp:forward>
</body>
</html>
Printdatejsp
<html>
<body>
<% out.print("Today
is:"+java.util.Calendar.getInstance().getTime()); %>
<%=
request.getParameter("name") %>
</body>
</html>
jsp:include action tag without parameter
// index.jsp
<h2>this is index
page</h2>
<jsp:include
page="printdate.jsp" />
<h2>end section of index
page</h2>
printdate.jsp
<% out.print("Today
is:"+java.util.Calendar.getInstance().getTime()); %>
Really I enjoy your blog with an effective and useful information. Very nice post with loads of information. Thanks for sharing with us.
ReplyDeleteCore Java Training
best java training institute in chennai with placement