This week's book giveaway is in the Mac OS forum.
We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line!
See this thread for details.
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


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