JSP Basics: Include Dynamic Content at Runtime

This method of including content reads the file at run-time after the JSP has been compiled. Changes to the included file are seen immediately and do not require recompilation of the JSP.


To include the file footer.jsp at runtime, use the following syntax:

 

About Quinn McHenry

Quinn was one of the original co-founders of Tech-Recipes. He is currently crafting iOS applications as a senior developer at Small Planet Digital in Brooklyn, New York.
View more articles by Quinn McHenry

The Conversation

Follow the reactions below and share your own thoughts.

One Response to “JSP Basics: Include Dynamic Content at Runtime”

  1. December 24, 2010 at 8:20 pm, Vokankh said:

    you can do import like that:

    the root directory is (“/”) is your WEB dir.

    Reply

Leave a Reply

You may also like-

How to Manually Install Tomcat on Windows 7How to Manually Install Tomcat on Windows 7Apache Tomcat is an open source web server and servlet container created by the Apache Software Foundation. It's used to execute to Java servlets ... Tomcat: How to Set the JAVA_HOME Enviroment VariableTomcat: How to Set the JAVA_HOME Enviroment VariableModify the catalina.bat file so that the servlet engine can work with Java in Tomcat. Catalina is Tomcat's servlet container that implements specifications for ...