Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

difference between jsp:include jsp:forward and regular include

 
preeti khane
Ranch Hand
Posts: 93
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
//file1.jsp
programAlerts = "showBodyProgram.jsp"
+ "?programPosition=" + "EntityAlerts" + "&showProgramHeader=true" + "&programHeader=xxx"; //1
<template:insert template="entityBodyTemplate.jsp">
<template :put name="alerts" content="<%=programAlerts%>"/>
</template:insert>
//showBodyProgram.jsp
<table border="0" cellspacing="0" cellpadding="0" width="460" align="center">
<jsp:include page="showScriptProgram.jsp" flush="true">
<jsp :param name="programType" value="body"/>
</jsp:include>
</table>
//showScriptProgram.jsp
<%
String programPosition = request.getParameter("programPosition");
String showProgramHeader = request.getParameter("showProgramHeader");
String programHeader = request.getParameter("programHeader"); //2
//some processing on programHeader
programHeader = UtilityAction.getResourcesValue(locale,headerImg); // 3
%>
<jsp:include page="showContentListProgram.jsp" flush="true">
<jsp :param name="programHeader" value="<%=programHeader%>"/> // 4
</jsp:include>
//showContentListProgram.jsp
String showProgramHeader = request.getParameter("showProgramHeader");
String programHeader = request.getParameter("programHeader"); //5
When I display programHeader finally in showContentListProgram.jsp I should have got the value set at 3/4, rather it displayed the value set at 1... Is this normal?
(Edited to disable smilies)
[ March 19, 2003: Message edited by: Cindy Glass ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic