tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yiu Wing" <yiuwing...@yahoo.com>
Subject Re: [repost] loading class files
Date Tue, 20 Nov 2001 02:33:31 GMT
[...]
> > But from one of the
> > Tomcat's docs, which is tomcat-docs\appdev\deployment.html, in its mid
> page
> > says,
> >
> > /WEB-INF/lib/ - This directory contains JAR files that contain Java
class
> > files (and associated resources) required for your application, such as
> > third party class libraries or JDBC drivers.
> >
> > I've copied my JDBC driver there, but it just won't work.  My citation
is
> > just the opposite of your reference email, which says that JAR files are
> > static content and can't be place under /WEB-INF.  Since my applet is
> > running now, and so think the docs could be wrong or haven't covered
this
> > topic completely. I hope someone could look this up.
> >
> > Anyway, thanks very much for your email again.  You have saved me!
> >[...]
>
>
> Thanks for your thanking!  :-)

I was very frustrated, I was trying to get this working for a week and I
didn't get anywhere, that's why the big thanks ;-).

> BTW, there are two kinds of class/jar in a webapp:
>   - for Servlet/jsp(it works in server-side)
>   - for Applet or other static content(it will be downloaded to
>     client together with Applet class, and works in client-side)
>
> I think the reference email means:
>    - class/jar for Servlet/jsp itself should be put under WEB-INF
>    - class/jar for static content should Not be put under WEB-INF
>
> I think your JDBC driver is used by your JSP directly, it works in
> server-side, (it is not downloaded together with  your Applat and
> work in client-side), so now, as you say, your JDBC driver should
> be put in WEB-INF/lib.
>

I'm just wondering the JDBC driver is working on the client side, cos' if I
place the driver jar file in WEB-INF/lib directory then it can't be found.
I've also tried the common/lib directory, as the other helpful folk
suggested, and it can't be found there, either.  I've actually embedded my
database connection in the applet, so it does look like I should place the
driver on a separate directory.


[snip]


--
To unsubscribe:   <mailto:tomcat-user-unsubscribe@jakarta.apache.org>
For additional commands: <mailto:tomcat-user-help@jakarta.apache.org>
Troubles with the list: <mailto:tomcat-user-owner@jakarta.apache.org>


Mime
View raw message