This week's book giveaway is in the Other Languages forum.
We're giving away four copies of Functional Reactive Programming and have Stephen Blackheath and Anthony Jones on-line!
See this thread for details.
Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

include a jsp within a jsp and passing a parameter

 
Pinda Ros
Ranch Hand
Posts: 65
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
I know it is possible to use the tag jsp:forward="filename.jsp?param" and call another jsp page passing a parameter...
Is it possible to include a jsp within another jsp and passing a parameter to the included jsp?
for example
<%@ include file="filename.jsp?param"%> ?something similar to this?

Thank you in advance
 
Jeroen Wenting
Ranch Hand
Posts: 5093
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No, it's not. The <%@ include %> tag is a static include, like a C #include.
It should (I think) work if you use <jsp:include > which does a dynamic include.
 
Pinda Ros
Ranch Hand
Posts: 65
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello and thank you for your reply.
So one of the main differences between <%include file=".."%>
and <%jsp:ionlcude=".."%> is that the one is static and the other is dynamic?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic