error "Status 404" on redirect
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   dachih_naraw
Posted On:   Wednesday, July 10, 2002 08:52 AM

Hi,all. I have two *.jsp files ( first.jsp and second.jsp ) in the same directory and I need redirect to second.jsp from first.jsp . I try "forward()" and "sendRedirect()" methods. getServletContext().getRequestDispatcher("/second.jsp").forward(request,response); //response.sendRedirect("/second.jsp"); I get this error message. type Status report message /second.jsp description The requested resource (/second.jsp) is not available. Tell me please, what's wrong? I use tomcat 4.0.3. Thank You.    More>>

Hi,all.

I have two *.jsp files ( first.jsp and second.jsp ) in the same directory and I need redirect to second.jsp from first.jsp .


I try "forward()" and "sendRedirect()" methods.


getServletContext().getRequestDispatcher("/second.jsp").forward(request,response);

//response.sendRedirect("/second.jsp");


I get this error message.


type Status report

message /second.jsp

description The requested resource (/second.jsp) is not available.


Tell me please, what's wrong?
I use tomcat 4.0.3.

Thank You.

   <<Less

Re: error "Status 404" on redirect

Posted By:   Bhaskar_Goyal  
Posted On:   Wednesday, July 10, 2002 11:56 AM

Hi,



Try it out


getServletContext().getRequestDispatcher("./second.jsp").forward(request,response);


getServletContext().getRequestDispatcher("second.jsp").forward(request,response);




Bhaskar Goyal
About | Sitemap | Contact