On Thu, 20 Jun 2002, Kiev Gama wrote:

> Hello all,
>
> I have the Tomcat 4.0.3 installed, and I am trying to load a .properties
> file necessary to my application(which has its classes and packages in the
> WEB-INF/classes) but I haven't got any success in doing this.
>
> I'v already tried to put the file in the WEB-INF/classes directory of my
> application, also tried to jar it and put the jarred file in the
> WEB-INF/lib.
> None of the above worked.
>
> I wanted to make it easy to transport the whole application without having
> to save that .properties in a directory outside the application's
> subdirectories.
>
> Does anybody know what I have to do in order to get that to work?

Well, you don't give too much info, like where you tried putting it
(other than that one location), and how you tried loading it.  But my
understanding is that if you put a file, say, called filename,
immediately under WEB-INF/, you can get to it by doing
getServletContext().getResource("filename").

Milt Epstein
Research Programmer
Systems and Technology Services (STS)
Campus Information Technologies and Educational Services (CITES)
University of Illinois at Urbana-Champaign (UIUC)
[EMAIL PROTECTED]


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to