tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Luc Foisy" <Luc.Fo...@technical-magic.com>
Subject RE: JSP Question
Date Wed, 08 Jan 2003 20:30:06 GMT
Actually, after the post I figure using the <%@ include file"filename" %> would be useless
because it was static
So I started to look at <%jsp:include ... \> for dynamic includes, and then soon realized
it was more trouble that it was worth :)

So I have decided just to redirect to individual jsp pages based on applicationJar.getPageName()
instead of including dynamic content in a common page

> -----Original Message-----
> From: Ricardo_Bosch@iwaysoftware.com
> [mailto:Ricardo_Bosch@iwaysoftware.com]
> Sent: Wednesday, January 08, 2003 3:16 PM
> To: tomcat-user@jakarta.apache.org
> Subject: RE: JSP Question
> 
> 
> I may be referring to an oldschool version of tomcat but the 
> include directive occurs during compilation, not execution.  
> So to do what you want you'd have to say
> <%	if(goo){	%>
> <%@ include file="filenameA" %>
> <%	}else{	%>
> <%@ include file="filenameB" %>
> <%	}	%>
> 
> or
> 
> do your thing the other way around and redirect to different 
> pages with <SOME DEFAULT PAGE STUFF HERE> incuded instead.
> 
> -rick
> 
> -----Original Message-----
> From: Luc Foisy [mailto:Luc.Foisy@technical-magic.com]
> Sent: Wednesday, January 08, 2003 1:54 PM
> To: Tomcat User List (E-mail)
> Subject: JSP Question
> 
> 
> 
> I am trying to use <%@ include file="filename" %>
> 
> I am sending to the page that has this with the line:
> response.sendRedirect("main.jsp?p="+applicationJar.getPageName());
> 
> So in main.jsp I would like to include an external file to 
> insert into a default page, something like:
> 
> <SOME DEFAULT PAGE STUFF HERE>
> <%@ include file="filename" %>
> <SOME DEFAULT PAGE STUFF HERE>
> 
> but I would like to replace "filename" with request.getParameter("p")
> 
> Any one have any idea how to do this?
> 
> --
> To unsubscribe, e-mail:   
> <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail: 
> <mailto:tomcat-user-help@jakarta.apache.org>
> 

--
To unsubscribe, e-mail:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-user-help@jakarta.apache.org>


Mime
View raw message