----------------------------------------------------
Please read the FAQ at <http://java.apache.org/faq/>
It does have a search feature!

We cannot guess what you are trying to do:
#1. Include version numbers for all software.
#2. Include relevant configuration settings.
#3. Include full descriptions of the problem.

Got Linux? Seeing lots of java processes?
<http://java.apache.org/faq/?file=274>
----------------------------------------------------


 > I am using gnujsp version 0.9.10
 > Apache web server version 1.3.9
 > Apache JServ version 1.0b
 >
 > I am calling a server side class (bean class), which calls a jsp file,
 > and I am using methods viz.
 > HttpServletRequest.setAttribute() and HttpServletresponse.callPage() and
 > I am getting Classcast exception.
 >
 > But the inslation guide of gnujsp-0.9.10 says that the se methods are
 > not supported.
 >
 > Now, what can I do to make these methods work or are there any other
 > alternate methods?
 >

Assuming you're using gnujsp .9, here's a work-around:

Stash all the info you need in the session, and then use 
response.sendRedirect(). to redirect to the .jsp you would have invoked via 
callPage().  Don't forget to use encodeURL() on the jsp URL.  I guess this 
causes an extra server-browser access (the browser has to GET the 
redirected .jsp, instead of receiving it as the response to the POST.)

If you want to get ugly, you could also:  hack the JSPServlet class in 
gnujsp to include a new public method that redirects to a .jsp you specify; 
then, build your servlets to include an instance of JSPServlet.  When you 
want to fake a callPage() in your servlet, call the new method.  Not 
pretty, but it can be made to work.

I'd move to gnujsp10 -- the jsp syntax is a lot different, and I would say 
its better to get your pages in 1.0 format sooner rather than later.

- Fernando


--
--------------------------------------------------------------
Please read the FAQ! <http://java.apache.org/faq/>
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Archives and Other:  <http://java.apache.org/main/mail.html>
Problems?:           [EMAIL PROTECTED]

Reply via email to