The Document Structure in Practice

To make this work, you'll create several subdirectories under the JSP parent directory. The overall structure will follow this form:

JSP ->
   index.jsp
   cust ->
     Login.jsp
   images ->
     bfglogo.jpg
     products ->
       34545656large.jpg
       34545656small.jpg
   includes ->
      bfgheader.jsp
      bfgfooter.jsp

To organize the file layout better, you'll create a number of directories to hold specific groups of pages (pages related to account maintenance under cust, product display pages under product, and so on). All the images will live under their own directory, with product images in a subdirectory by themselves. Finally, you will use a directory called include to hold the header and footer information.

When the organization has begun to ...

Get MySQL™ and JSP™ Web Applications: Data-Driven Programming Using Tomcat and MySQL now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.