JSP Include Me

Sometime back I wrote Import Script, Import CSS, Import PHP where I showed how to import external files in PHP and JSP. At this time I want to elaborate a little more on importing external JSP files from another JSP. One way to import another JSP files to statically import it using the following construct:

<%@ include file="path/to/file.jsp" %>

For the best performance use the above method for importing JSP code from another JSP file. To dynamically include a JSP file into another one you can use the following:

<jsp:include page="path/to/file.jsp" />

Related posts:

  1. Import Script, Import CSS, Import PHP
  2. Java Five-Oh #3: Variable Arguments
  3. Run PHP Web Applications on the Java Platform
  4. Embedding Groovy
  5. AJAX Header Rotator

This entry was posted in Java, TechKnow. Bookmark the permalink. Post a comment or leave a trackback: Trackback URL.

Post a Comment

Your email is never published nor shared. Required fields are marked *

*
*