O'Reilly logo

Sams Teach Yourself J2EE™ in 21 Days by Peter Roxburgh, Andy Longshaw, Debbie Law, Dan Haywood, Martin Bond

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Accessing HTTP Servlet Variables

The JSP pages you write are translated into servlets that process the HTTP GET and POST requests. The JSP code can access servlet information using implicit objects defined for each page. These implicit objects are pre-declared variables that you can reference from the Java code on your JSP. The most commonly used objects are shown in Table 13.3.

Table 13.3. JSP Implicit Objects
Reference Name Class Description
config javax.servlet.ServletConfig The servlet configuration information for the page
request subclass of javax.servlet.ServletRequest Request information for the current HTTP request
session javax.servlet.http.HttpSession The servlet session object for the client
out javax.servlet.jsp.JspWriter A subclass ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required