JSP Include Param
JSP Include Param is used to pass parameter in the include directive. The example uses <jsp:param> clause to pass the parameter name and value to the dynamic jsp page. This clause is only used with the <jsp:include> directive. It allows you to include either a static or dynamic file in a JSP page. The <jsp:include> acts on a request and sends back the result included in the JSP page.
Understand with Example
The Tutorial illustrate an example from 'JSP Include Param'. To understand the example we create a include.jsp that include <jsp:include page> directive 'includedparam.jsp'. The <jsp:param> clause to pass the username and password parameter value to the dynamic jsp. The Request.getParameter ( ) retrieve the value that client has submitted. The <jsp:include> act on the request and send back the result included in the include.jsp page.
Here is the code of include.jsp
Here is the code of includedParam.jsp
Output will be displayed as: