How to pass all URL parameters through a <jsp:include> tag?

112 views Asked by At

I have a JSP page which is called with various URL parameters like this: http://myserver.com/page_A.jsp?paramA=hello&paramB=you

This page however doesn't do anything with the URL parameters; it's just supposed to pass them on to a second JSP page page_B.jsp.

I know I can call in page_A.jsp the second page easily with fixed parameters:

<!-- this is part of page_A.jsp -->
<jsp:include page="page_B.jsp">
        <jsp:param name="paramA" value="hello" />
        <jsp:param name="paramB" value="you" />
</jsp:include>

But how can I pass dynamically all parameters given to page_A.jsp through to page_b.jsp?

0

There are 0 answers