tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Phillip Gillis" <p...@FocusedMediaGroup.com>
Subject Re: Newbie - 500 Error
Date Tue, 10 Jul 2001 06:39:04 GMT
Thank you so much for your help. I know I jumped the gun and asked before I
thoroughly researched . However, I was and am very anxious to begin my
conversions . .and I think I understand the particular syntax I am looking
at . . but I was oblivious to the spec and set-up. I will now go back to the
drawing board and learn this correctly. The goal certainly is not to use IIS
for production, but these are the only machines we have for development. It
is nice to know that I can actually pursue it on the Win platform though to
be honest.
It is very satisfying to know that people like you and others on this list
contribute your time and knowledge. I cannot say thanks enough. Perhaps
someday I can help you back . .perhaps I can remind you if you'd like fries
with your burger or something

:-)

thanks again.

Phil


----- Original Message -----
From: "Dmitri Colebatch" <dim@nuix.com.au>
To: "Phillip Gillis" <phil@focusedmediagroup.com>
Cc: <tomcat-user@jakarta.apache.org>
Sent: Tuesday, July 10, 2001 1:36 AM
Subject: Re: Newbie - 500 Error


> On Tue, 10 Jul 2001 16:21, Phillip Gillis wrote:
> > So I take it the directory structure is critical :-)
> Yep... have a look at the servlet 2.2 spec - coming from an asp world I'm
> guessing you're not familiar with the way java works - but basically
almost
> everything you deal with in java will conform to some spec.  The spec
holds
> the rulebook - that way you can stop using one vendor's product and start
> using anothers'.  (notice M$ doesn't do this (o:  ... sorry - couldn't
> resist)...
> http://java.sun.com/products/servlet <- the spec is in there somewhere,
> tomcat 3.x support version 2.2 and 4.0 is aiming at 2.3.  I'd start with
2.2
> if I were you.
>
> > Again I am new to this . .a last question if you dont mind .
> >
> > If I were really wanting to house it in my wwwroot directory, couldn't I
> > keep the same "phil" structure, and modify my Context path statement?
Also,
> > do I have to reompile class files everytime I move them to a new
location?
> yep - absolutely.  but if you're wanting to integrate with IIS (I'm
assuming
> thats faster than tomcat with static pages) then read the IIS howto.  I'm
a
> linux user so have no idea about the IIS stuff sorry.  but if on the other
> hand all you want to do is use a familiar environment, then yeah, you can
> have the context docBase as an absolute path... eg C:/wwwroot/phil.
>
> one last thing from me... when replying - keep it on the list, that way
> someone else having the same questions can search the archives first (o:
>
> cheers
> dim
>
>
> >
> > Thanks again!!!
> >
> > Phil
> >
> >
> > ----- Original Message -----
> > From: "Dmitri Colebatch" <dim@nuix.com.au>
> > To: "Phillip Gillis" <phil@focusedmediagroup.com>
> > Cc: "Phillip L. Gillis" <phil@focusedmediagroup.com>
> > Sent: Tuesday, July 10, 2001 1:20 AM
> > Subject: Re: Newbie - 500 Error
> >
> > > ahh, no... here's your problem
> > >
> > > >         <Context path="/phil"
> > > >                  docBase="webapps/phil/jsp"
> > >
> > >                                         ^^^^^
> > >
> > > >                  crossContext="false"
> > > >                  debug="0"
> > > >                  reloadable="true" >
> > > >         </Context>
> > >
> > > It should be webapps/phil....  your requesting
> > > http://localhost:8080/phil/jsp/dates.jsp right?  The WEB-INF directory
> >
> > should
> >
> > > exist in the docBase directory.  You dont have this atm right?
> > >
> > > try that (o:
> > >
> > > cheers
> > > dim
> > >
> > > >  I have the following directory structure:
> > > >
> > > >  webapss
> > > >  -->phil
> > > >     -->jsp
> > > >     -->WEB-INF
> > > >
> > > > the jsp directory has date.jsp (copy of the examples file)
> > > > the WEB-INF directory has a subdirectory named classes, inside
classes
> >
> > is a
> >
> > > > sub directory named dates, inside dates is my JspCalendar.java.
Opening
> >
> > it
> >
> > > > in JPad and compiling puts the class file in the same directory:
> > > >
> > > >  "Compiling
> >
> >
C:\jakarta-tomcat-3.2.1\webapps\phil\WEB-INF\classes\dates\JspCalendar.java
> >
> > > > Finished"
> > > >
> > > > calling http://localhost:8080/phil/date.jsp in the browser still
gives
> >
> > me:
> > > > "org.apache.jasper.JasperException: Unable to load class
> >
> > dates.JspCalendar"
> >
> > > > My CLASSPATH is ".;C:\jdk1.1.8\bin"
> > > > My JAVA_HOME is "c:\jdk1.1.8"
> > > > ";C:\jdk1.1.8\bin" was appended to my PATH
> > > > My TOMCAT_HOME is "c:\jakarta-tomcat-3.2.1"
> > > >
> > > >
> > > > I am baffled.
> > > >
> > > > phil
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > ----- Original Message -----
> > > > From: "Dmitri Colebatch" <dim@nuix.com.au>
> > > > To: "Phillip Gillis" <phil@focusedmediagroup.com>;
> > > > <tomcat-user@jakarta.apache.org>
> > > > Sent: Tuesday, July 10, 2001 12:55 AM
> > > > Subject: Re: Newbie - 500 Error
> > > >
> > > > > Phil,
> > > > >
> > > > > Ok - you're using the
> >
> > %TOMCAT_HOME%\webapps\examples\jsp\dates\dates.jsp?
> >
> > > > > The line you're interested in is
> > > > >
> > > > > <jsp:useBean id='clock' scope='page' class='dates.JspCalendar'
> > > > > type="dates.JspCalendar" />
> > > > >
> > > > > This is more of a general java question rather than tomcat
(assuming
> >
> > I'm
> >
> > > > > understanding you correctly, so forgive me if I appear patronizing
> > > > > (o: ).
> > > > >
> > > > > What the jsp:useBean does is try to create an object of type
> > > > > "dates.JspCalendar".  This object is said to exist in a package
> >
> > "dates"
> >
> > > > and
> > > >
> > > > > be called "JspCalendar".  As such, tomcat will assume it exists in
> > > > > the directory webapps\phil\WEB-INF\classes\dates\ - now if I read
> >
> > correectly
> >
> > > > > you've put it in the classes dir.  When you compile, you shouldn't
> >
> > move
> >
> > > > files
> > > >
> > > > > around yourself... do something like
> > > > >
> > > > > javac -d %TOMCAT_HOME%\webapps\phil\WEB-INF\classes
JspCalendar.java
> >
> > and
> >
> > > > > you'll see that javac puts it in the correct place.  This it
> > > > > basically the way CLASSPATH operates in java...
> > > > >
> > > > > this should do the trick.
> > > > >
> > > > > cheesr
> > > > > dim
> > > > >
> > > > > On Tue, 10 Jul 2001 15:39, Phillip Gillis wrote:
> > > > > > Thank you for your reply . .
> > > > > > In my directory "Phil" I created a WEB-INF subdirectory, in
it I
> > > > > > created
> > > >
> > > > a
> > > >
> > > > > > sub directory named "classes" . inside the classes directory,
I
> >
> > placed
> >
> > > > the
> > > >
> > > > > > JSPCalendar class which from my error is what won't load, I
also
> >
> > placed
> >
> > > > the
> > > >
> > > > > > associated .java file in the clsses directory. Using JPad, I
> >
> > recompiled
> >
> > > > > > this with no errors replacing the previously copied class file.
> > > > > > In my Server.xml file, I now just have a Host name entry which
has
> >
> > the
> >
> > > > > > correct paths. I removed the  Context path entry. In the
browser, I
> >
> > see
> >
> > > > > > everything fine, but running the JSP . I still get my error.
> > > > > > My error is "java.lang.ClassNotFoundException: Unable to load
class
> > > > > > dates.JspCalendar "
> > > > > >
> > > > > > THANK YOU!!!
> > > > > >
> > > > > > Phil
> > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > > > ----- Original Message -----
> > > > > > From: "Dmitri Colebatch" <dim@nuix.com.au>
> > > > > > To: <tomcat-user@jakarta.apache.org>; "Phillip Gillis"
> > > > > > <phil@FocusedMediaGroup.com>
> > > > > > Sent: Tuesday, July 10, 2001 12:36 AM
> > > > > > Subject: Re: Newbie - 500 Error
> > > > > >
> > > > > > > I'm not sure if this is the your problem or not, but I
would
> >
> > suggest
> >
> > > > at
> > > >
> > > > > > least
> > > > > >
> > > > > > > having a WEB-INF with a plain web.xml in it so that you
conform
> > > > > > > to spec...
> > > > > > >
> > > > > > > what is the error you get?
> > > > > > >
> > > > > > > On Tue, 10 Jul 2001 15:19, you wrote:
> > > > > > > > Hello,
> > > > > > > >
> > > > > > > > I have just installed the JDK and Tomcat 3.2.1 on
Win Server
> >
> > 2000 .
> >
> > > > . .
> > > >
> > > > > > all
> > > > > >
> > > > > > > > of my example jsp files work fine. My problem is that
I am
> >
> > trying
> >
> > > > > > > > to
> > > > > >
> > > > > > create
> > > > > >
> > > > > > > > a directory to put my own jsp files. I  copied the
included
> > > > > > > > date.jsp
> > > > > >
> > > > > > file
> > > > > >
> > > > > > > > and put it in a directory named "phil", under webapps.
I
then
> >
> > made
> >
> > > > an
> > > >
> > > > > > entry
> > > > > >
> > > > > > > > into the server.xml file context path . .when I browse
to
the
> > > > > > > > directory,
> > > > > >
> > > > > > I
> > > > > >
> > > > > > > > see the jsp file . but when I try to run it, it won't
load
the
> > > > > > > > class
> > > > > >
> > > > > > file.
> > > > > >
> > > > > > > > I come from an ASP, IIS background so I am unsure
what to
do. I
> > > >
> > > > really
> > > >
> > > > > > want
> > > > > >
> > > > > > > > to create a "virtual directory" and do my jsp files
in it .
.
> >
> > but I
> >
> > > > am
> > > >
> > > > > > not
> > > > > >
> > > > > > > > having any luck doing anything outside the examples
directory.
> > > > > > > > I did
> > > > > >
> > > > > > look
> > > > > >
> > > > > > > > in the docs and in the archives, and I didn't see
anything
that
> > > >
> > > > helped
> > > >
> > > > > > me.
> > > > > >
> > > > > > > > Please keep in mind this is my start for doing jsp
. with
the
> > > >
> > > > intention
> > > >
> > > > > > of
> > > > > >
> > > > > > > > migrating my asp application over. Any help?
> > > > > > > >
> > > > > > > > Thanks in advance.
> > > > > > > >
> > > > > > > > Phil
> > > > > > >
> > > > > > > ----------------------------------------
> > > > > > > Content-Type: text/html; charset="iso-8859-1";
name="Attachment:
> >
> > 1"
> >
> > > > > > > Content-Transfer-Encoding: quoted-printable
> > > > > > > Content-Description:
> > > > > > > ----------------------------------------


Mime
View raw message