What is the difference between callling a RequestDispatcher
using ServletRequest and ServletContext?
Answer Posted / prachetash
RequestDispatcher rd = request.getRequestDispatcher("result.jsp")
This is relative path, becoz there is no "/" slash.Container looks in same logical path.
RequestDispatcher rd = getServletContext.getRequestDispatcher("/result.jsp")
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Does servlet have main method?
How can we invoke another servlet in a different application?
What is called Scriptlet?
Why servlet is faster than jsp?
How we can get ip address of client in servlet?
Why the container loads server at the application startup and how?
What is the difference between Servlets and Applets?
Can we fetch the attributes related to a servlet on a different servlet?
how many jsp scripting elements are there and what are those?
How to rectify errors in java servlet while compilation?
What do you mean by session tracking?
Why is servlet used?
Which event is fired at the time of project deployment and undeployment?
What are the key methods that are involved in processing of http servlets?
Write the code to get the server information in servlet.