You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Kitching Simon <Si...@orange.ch> on 2000/09/19 20:08:25 UTC
RE: tomat/linux - can't get jsp to work in dir other than exampl
es!
> -----Original Message-----
> From: Shailendra majmundar [SMTP:smaj@Zambeel.com]
> Sent: Tuesday, September 19, 2000 7:39 PM
> To: tomcat-user@jakarta.apache.org
> Subject: tomat/linux - can't get jsp to work in dir other than
> examples!
>
> I can access my servlets after configuring server.xml, but the jsps in
> WEB-INF directory won't work.
> Is there some magic to apache conf that I am missing? I don't see any jsp
> related tags in
> $TOMCAT_HOME/..examples/WEB-INF/web.xml.
>
> It seems to work only in the examples directory.
>
> Thanks
>
[Kitching Simon]
Hi,
I don't know if the above is just a typo, but
just in case it isn't, I'll point out:
jsp files do *not* go in the WEB-INF subdirectory of your
web application's main (root) directory. They go anywhere
you like under your web application's main directory
*except* under WEB-INF.
Servlet classes *do* go in the WEB-INF/classes subdirectory
of your web application's main (root) directory.
And you need to configure apache so that tomcat is invoked
for any URl which:
(a) ends in .jsp, or
(b) matches one of your servlets
It is always recommended that you get things working with
tomcat in "stand-alone" mode, ie without apache, then try
adding apache as a front-end afterwards.
You don't need to put any entries in yourwebapp/WEB-INF/web.xml
related to your jsp files, unless you are trying something really
tricky
like running a page's init function on startup.
Regards,
Simon