The code below provided in a servlet located at MyHost.com will redirect the application flow
and send the JavaSchool.com front page to a client browser.
RequestDispatcher dispatch = getServletContext().
getRequestDispatcher("http://javaschool.com");
dispatch.forward(request, response);
The code below provided in a JSP page located at MyHost.com will redirect the application flow
and send the current page data for processing by the JavaSchool.com.
<%@ include file="http://JavaSchool.com/process.jsp" %>
The code below provided in a JSP page located at MyHost.com will redirect the application flow
and send the JavaSchool.com front page to a client browser.
RequestDispatcher dispatch =
request.getRequestDispatcher("http://javaschool.com");
dispatch.forward(request, response);
The code below provided in a Struts Action located at MyHost.com will redirect the application flow
and send the current page data for processing by the JavaSchool.com.
RequestDispatcher dispatch = getServletContext().
getRequestDispatcher("http://javaschool.com");
dispatch.forward(request, response);
|