Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

to do a forward in servelt

 
aakash bhatt
Ranch Hand
Posts: 182
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In jso we have <jsp:forward> but in servelt how do i achieve the forward.
i want to do a forward instead of sendredirect how can i do ?

Thanks,
aakash
 
Raghunath Madhvapathi
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can use RequestDispatcher for forwarding from servlet.

RequestDispatcher rd = getServletContext().RequestDispatcher("relative url of jsp").forward(req,res);
 
Julian Kennedy
Ranch Hand
Posts: 823
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Those are a couple of interesting new technologies you've invented there, Ashaak! I'm not sure that I can comment on JSO and Servelts but with JSP and Servlets it can be done as follows, from doGet() or doPost():

Jules
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic