Look at projects such as tiles.

An alternative is to use jsp preludes. Which allow you to add stuff to the beginning or end of all jsp pages.

For example: put this in web.xml:
<jsp-config>
  <jsp-property-group>
    <url-pattern>*.jsp</url-pattern>
    <include-prelude>/WEB-INF/prelude1.jspf</include-prelude>
  </jsp-property-group>
</jsp-config>


-Tim

coder5436uk wrote:
I have an install of tomcat and I wish to add a default header and footer to
each page, any one know how to do this ?

I am running files which come out with simple text, I want to include them
all in a site template without having to change the code in each page.

eg. simple page <%= hello %>

will out put the java variable "hello" on a blank page, I want to simulate
the code
<%@ include file="header.html" %>

<%= hello %>

<%@ include file="header.html" %>

without having to put the JSP include in every page
I would appreciate some help on how to do this within the tomcat config


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to