You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by anunay ashish <an...@tis.co.in> on 2003/10/13 10:32:30 UTC

Unable to locate JSP page from Servlet.

Hi,
I am calling a JSP page from a servlet as follows:
try
  {
   //set the attribute and forward to pageFormat.jsp
   request.setAttribute("servletName", "addDataServlet");

getServletConfig().getServletContext().getRequestDispatcher("/Tracking_syste
m/pageFormat.jsp").forward(request, response);
  }
  catch (Exception ex)
  {
   ex.printStackTrace ();
  }

But the error I am getting is HTTP Status 404.
Physically the JSP file is present in that folder.
Why is the my application not able to locate my JSP page?
Where am I going wrong?
Thanks in advance?

----- Original Message -----
From: "Martin Jacobson" <ma...@libero.it>
To: "Tomcat Users List" <to...@jakarta.apache.org>
Sent: Monday, October 13, 2003 1:38 PM
Subject: Re: tomcat and mac os 10.2.8 update


> Giuliano Gavazzi wrote:
>
> > was /usr/local a symbilic link? If so the installation might have
> > replaced it with a directory. so you should copy the new content to the
> > target and reinstate the symbilic link.
> >
> > BTW Using JAVA_HOME:       /usr sounds wrong to me.
> >
> No, that's right for Mac OS X
>
> Martin
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Unable to locate JSP page from Servlet.

Posted by Twan Munster <t....@emaxx.nl>.
go to http:\\localhost:8080
--> manager
en klik on the folder where servlet is and click reload


----- Original Message ----- 
From: "anunay ashish" <an...@tis.co.in>
To: "Tomcat Users List" <to...@jakarta.apache.org>; "Twan Munster"
<t....@emaxx.nl>
Sent: Monday, October 13, 2003 10:43 AM
Subject: Re: Unable to locate JSP page from Servlet.


> How do we reload servlet in Tomcat manager?
> ----- Original Message -----
> From: "Twan Munster" <t....@emaxx.nl>
> To: "Tomcat Users List" <to...@jakarta.apache.org>
> Sent: Monday, October 13, 2003 2:06 PM
> Subject: Re: Unable to locate JSP page from Servlet.
>
>
> > Hello,
> >
> > You've correctly configured your sitemap? En maybe you have to restart
> > tomcat,
> > or reload the servlet in the tomcat manager.
> >
> > good luck
> >
> > Twan
> > ----- Original Message -----
> > From: "anunay ashish" <an...@tis.co.in>
> > To: "Tomcat Users List" <to...@jakarta.apache.org>
> > Sent: Monday, October 13, 2003 10:32 AM
> > Subject: Unable to locate JSP page from Servlet.
> >
> >
> > > Hi,
> > > I am calling a JSP page from a servlet as follows:
> > > try
> > >   {
> > >    //set the attribute and forward to pageFormat.jsp
> > >    request.setAttribute("servletName", "addDataServlet");
> > >
> > >
> >
>
getServletConfig().getServletContext().getRequestDispatcher("/Tracking_syste
> > > m/pageFormat.jsp").forward(request, response);
> > >   }
> > >   catch (Exception ex)
> > >   {
> > >    ex.printStackTrace ();
> > >   }
> > >
> > > But the error I am getting is HTTP Status 404.
> > > Physically the JSP file is present in that folder.
> > > Why is the my application not able to locate my JSP page?
> > > Where am I going wrong?
> > > Thanks in advance?
> > >
> > > ----- Original Message -----
> > > From: "Martin Jacobson" <ma...@libero.it>
> > > To: "Tomcat Users List" <to...@jakarta.apache.org>
> > > Sent: Monday, October 13, 2003 1:38 PM
> > > Subject: Re: tomcat and mac os 10.2.8 update
> > >
> > >
> > > > Giuliano Gavazzi wrote:
> > > >
> > > > > was /usr/local a symbilic link? If so the installation might have
> > > > > replaced it with a directory. so you should copy the new content
to
> > the
> > > > > target and reinstate the symbilic link.
> > > > >
> > > > > BTW Using JAVA_HOME:       /usr sounds wrong to me.
> > > > >
> > > > No, that's right for Mac OS X
> > > >
> > > > Martin
> > > >
> > > >
> > >
> ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> > > > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> > > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> > >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Unable to locate JSP page from Servlet.

Posted by anunay ashish <an...@tis.co.in>.
How do we reload servlet in Tomcat manager?
----- Original Message -----
From: "Twan Munster" <t....@emaxx.nl>
To: "Tomcat Users List" <to...@jakarta.apache.org>
Sent: Monday, October 13, 2003 2:06 PM
Subject: Re: Unable to locate JSP page from Servlet.


> Hello,
>
> You've correctly configured your sitemap? En maybe you have to restart
> tomcat,
> or reload the servlet in the tomcat manager.
>
> good luck
>
> Twan
> ----- Original Message -----
> From: "anunay ashish" <an...@tis.co.in>
> To: "Tomcat Users List" <to...@jakarta.apache.org>
> Sent: Monday, October 13, 2003 10:32 AM
> Subject: Unable to locate JSP page from Servlet.
>
>
> > Hi,
> > I am calling a JSP page from a servlet as follows:
> > try
> >   {
> >    //set the attribute and forward to pageFormat.jsp
> >    request.setAttribute("servletName", "addDataServlet");
> >
> >
>
getServletConfig().getServletContext().getRequestDispatcher("/Tracking_syste
> > m/pageFormat.jsp").forward(request, response);
> >   }
> >   catch (Exception ex)
> >   {
> >    ex.printStackTrace ();
> >   }
> >
> > But the error I am getting is HTTP Status 404.
> > Physically the JSP file is present in that folder.
> > Why is the my application not able to locate my JSP page?
> > Where am I going wrong?
> > Thanks in advance?
> >
> > ----- Original Message -----
> > From: "Martin Jacobson" <ma...@libero.it>
> > To: "Tomcat Users List" <to...@jakarta.apache.org>
> > Sent: Monday, October 13, 2003 1:38 PM
> > Subject: Re: tomcat and mac os 10.2.8 update
> >
> >
> > > Giuliano Gavazzi wrote:
> > >
> > > > was /usr/local a symbilic link? If so the installation might have
> > > > replaced it with a directory. so you should copy the new content to
> the
> > > > target and reinstate the symbilic link.
> > > >
> > > > BTW Using JAVA_HOME:       /usr sounds wrong to me.
> > > >
> > > No, that's right for Mac OS X
> > >
> > > Martin
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> > > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Unable to locate JSP page from Servlet.

Posted by Twan Munster <t....@emaxx.nl>.
Hello,

You've correctly configured your sitemap? En maybe you have to restart
tomcat,
or reload the servlet in the tomcat manager.

good luck

Twan
----- Original Message ----- 
From: "anunay ashish" <an...@tis.co.in>
To: "Tomcat Users List" <to...@jakarta.apache.org>
Sent: Monday, October 13, 2003 10:32 AM
Subject: Unable to locate JSP page from Servlet.


> Hi,
> I am calling a JSP page from a servlet as follows:
> try
>   {
>    //set the attribute and forward to pageFormat.jsp
>    request.setAttribute("servletName", "addDataServlet");
>
>
getServletConfig().getServletContext().getRequestDispatcher("/Tracking_syste
> m/pageFormat.jsp").forward(request, response);
>   }
>   catch (Exception ex)
>   {
>    ex.printStackTrace ();
>   }
>
> But the error I am getting is HTTP Status 404.
> Physically the JSP file is present in that folder.
> Why is the my application not able to locate my JSP page?
> Where am I going wrong?
> Thanks in advance?
>
> ----- Original Message -----
> From: "Martin Jacobson" <ma...@libero.it>
> To: "Tomcat Users List" <to...@jakarta.apache.org>
> Sent: Monday, October 13, 2003 1:38 PM
> Subject: Re: tomcat and mac os 10.2.8 update
>
>
> > Giuliano Gavazzi wrote:
> >
> > > was /usr/local a symbilic link? If so the installation might have
> > > replaced it with a directory. so you should copy the new content to
the
> > > target and reinstate the symbilic link.
> > >
> > > BTW Using JAVA_HOME:       /usr sounds wrong to me.
> > >
> > No, that's right for Mac OS X
> >
> > Martin
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org