Chapter 28. Packaging a JSP Application

In this chapter

You might have noticed that servlets and Java Server Pages don't mix well when it comes to naming. So far, most of the servlets you have used are accessed using the /servlet/ prefix. The problem with that is, when the servlet needs to invoke a JSP, it must include the full pathname of the JSP. Although that might be fine for testing, in a real-world application, you shouldn't have to rewrite a JSP or a servlet just because you want to move your application to a different directory.

The servlet API defines a way for you to package together your JSPs, Java classes, and servlets ...

Get Special Edition Using Java™ Server Pages and Servlets 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.