How to forward a request to another source?



How to forward a request to another source?..

Answer / Vimal Kumar

In JSP, you can use the RequestDispatcher object to forward a request to another resource within the same web application. Here's an example: n`RequestDispatcher rd = request.getRequestDispatcher("/destinationPage");nrd.forward(request, response);`

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More JSP Interview Questions

Why does _jspService() start with an ‘_’ but other lifecycle methods do not?

1 Answers  


What is the purpose of <jsp:setproperty >?

1 Answers  


What is jsp technology?

1 Answers  


What is contextpath in jsp?

1 Answers  


What is Include directive?

1 Answers  


Is it possible to share an httpsession between a jsp and ejb? What happens when I change a value in the httpsession from inside an ejb?

1 Answers  


How do I view a jsp file?

1 Answers  


What are the jsp lifecycle phases?

1 Answers  


When i am useing useBean tag of JSP in weblogic server It show compiletion error..Like bad class file: C:\bea\user_projects\domains\Mahesh\applications\UseBean\WEB-INF\classes\user\UserData.class class file has wrong version 49.0, should be 48.0 Please remove or make sure it appears in the correct subdirectory of the classpath. user.UserData user1 = null; //[ /SaveName.jsp; Line: 4]

1 Answers  


What is difference between custom jsp tags and beans?

1 Answers  


What is tld file?

1 Answers  


When does a container initialize multiple jsp / servlet objects?

1 Answers  


Categories