• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

forward from servlet to ASP

 
Ranch Hand
Posts: 38
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,
I build a servlet that use the requestDispatcher , setAttribute methods to forward the visitors to another sites and sending confidential parameters like password .
But it seems that it doesn't work correctly because my jserv is 1.0.2 and in my jserv.log i have the following error message : setattribute method not found and same message to the requestDispatcher .
How can i make this scenario using the SendRedirect method .
Please advise me any hint or solution about this issue .
Thank you in advance,
Best regards .
Fouad .
 
Ranch Hand
Posts: 168
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You can only forward to another servlet. So RequestDispatcher won't do you any good if you are trying to get to a non-servlet.
But you can always do
 
Ranch Hand
Posts: 251
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Just to clarify, JSPs are servlets too, so you can forward to servlets & JSPs, but not any other kind of file. Use the response.sendRedirect()
 
Sheriff
Posts: 4313
Android IntelliJ IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
to get even MORE specific... you can only forward or include other files within the same web app.
.... granted, if you want to forward/include something in a different webapp you can do that... you just have to do a lil extra work and get a reference to the other web app (currentServletContext.getContext(uri) and then get a reference to THAT web app's RequestDispatcher...
but anyway --- yeah, you're gonna have to use sendRedirect() if you want to go to an .asp
[ April 16, 2003: Message edited by: Jessica Sant ]
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic