File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Servlets and the fly likes Passing an HttpServletRequest object Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Passing an HttpServletRequest object" Watch "Passing an HttpServletRequest object" New topic
Author

Passing an HttpServletRequest object

Joe McGuire
Ranch Hand

Joined: Mar 19, 2001
Posts: 293
I've got a servlet that passes the HttpServletRequest "req" to a utility class that is to extract the parameters (using the req.getParameter( "parametername" ) method, and build an http page using those parameters.
For some reason, the req object being passed is empty (or it may be that the parameters cannot be passed this way?). Can the HttpServletRequest be used outside the servlet like this?
Tony Alicea
Desperado
Sheriff

Joined: Jan 30, 2000
Posts: 3222
    
    5
I don't see why not. Is the "req" inside the utility class null or just the params?


Tony Alicea
Senior Java Web Application Developer, SCPJ2, SCWCD
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Passing an HttpServletRequest object
 
Similar Threads
can any tell what is passed to init() method...
Finding the type browser from Servlet
Single Thread Model
Passed
Reading parameters in Servlet passed from Client